-
Notifications
You must be signed in to change notification settings - Fork 15.5k
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
fix: handle null/undefined options for fs.readdir #34764
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM w/ nit
Looks like webpack/webpack#10227 - we can probably fix this but yeah let's do it in another PR! |
cb218b0
to
2bd8586
Compare
@dsanders11 patch LGTM, but needs an update to resolve merge conflicts |
2bd8586
to
9acce51
Compare
Release Notes Persisted
|
Co-authored-by: David Sanders <[email protected]>
Co-authored-by: David Sanders <[email protected]>
I have automatically backported this PR to "21-x-y", please check out #36846 |
I have automatically backported this PR to "20-x-y", please check out #36847 |
I have automatically backported this PR to "23-x-y", please check out #36848 |
I have automatically backported this PR to "22-x-y", please check out #36849 |
fix: handle null/undefined options for fs.readdir (#34764) Co-authored-by: David Sanders <[email protected]> Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com> Co-authored-by: David Sanders <[email protected]>
fix: handle null/undefined options for fs.readdir (#34764) Co-authored-by: David Sanders <[email protected]> Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com> Co-authored-by: David Sanders <[email protected]>
Co-authored-by: David Sanders <[email protected]>
* fix: handle null/undefined options for fs.readdir (#34764) Co-authored-by: David Sanders <[email protected]> * chore: remove optional chaining Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com> Co-authored-by: David Sanders <[email protected]>
Description of Change
Fixes isaacs/node-graceful-fs#223 in Electron. I also have a PR on that repo to improve their behavior (which would also fix the issue), so I'm fixing it from all angles.
This moves
fs.readdir
slightly closer to the typings from Node, but there's still other issues (options
could be a string). I plan on doing a more general improvement PR to fix up behavior inlib/asar/fs-wrapper.ts
.Checklist
npm test
passesRelease Notes
Notes: Fixed an error when fs.readdir gets null for options