module: rename anonymous functions by ranstyr · Pull Request #13849 · nodejs/node
This is my first contribution!
#GoodnessSquad
#8913
Checklist
-
make -j4 test(UNIX), orvcbuild test(Windows) passes - tests and/or benchmarks are included
- documentation is changed or added
- [X ] commit message follows commit guidelines
Affected core subsystem(s)
#GoodnessSquad
| var nodePath = process.env['NODE_PATH']; | ||
| if (nodePath) { | ||
| paths = nodePath.split(path.delimiter).filter(function(path) { | ||
| paths = nodePath.split(path.delimiter).filter(function pathsFilterCallback(path) { |
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this is the only one that's necessary. The rest should show up as expected in stack traces, etc. because they're attached to an object (prototype or otherwise).
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I agree, this is the only one that is needed. Can you please restore the other ones?
Nice work. Please feel free to also give us any feedback about the onboarding process today.
Note that JavaScript functions are automatically named when you assign them since ES2015.
LGTM on the change @mcollina approved, please amend the rest.
I think this PR could be closed due to #14297 (review).
There's one function in module.js that needs to be named, so this can stay open in the hopes that the original submitter updates it or possibly an existing Collaborator can come along and update it.
@ranstyr please feel free to reopen if you want to follow up on this!
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters