Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Traverse all option #13

Merged
merged 2 commits into from
Sep 23, 2018
Merged

Conversation

jskrzypek
Copy link
Contributor

@jskrzypek jskrzypek commented Sep 16, 2018

Implements suggestion in #11 (comment)

if (isUnderDepthLimit && ((opts.filter && opts.filter(item)) || !opts.filter)) ls = klawSync(pi, opts, ls)
} else if (!st.isDirectory()) {
if (!opts.nofile) { if ((opts.filter && opts.filter(item)) || !opts.filter) ls.push(item) }
if (shouldAdd) {
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jskrzypek will you please use one line if statement here?

if (shouldAdd) {
ls.push(item)
}
if (shouldTraverse) {
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also please use one line if statement here.

@manidlou
Copy link
Owner

@jskrzypek thanks for your contribution! I just added little comments. Other than that, code LGTM!

@manidlou
Copy link
Owner

Actually it is fine! We'll take care of formatting later as I want to release this as quickly as possible!

@manidlou manidlou merged commit 28acfba into manidlou:master Sep 23, 2018
@jskrzypek
Copy link
Contributor Author

@manidlou sorry, I was on holiday, glad the pr worked out :)

@jskrzypek jskrzypek deleted the feat-traverse-all branch September 25, 2018 16:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants