sindresorhus / globby

User-friendly glob matching
MIT License
2.49k stars 126 forks source link

Fix `ignore` and `expandDirectories` default handling #252

Closed aaronccasanova closed 1 year ago

aaronccasanova commented 1 year ago

Hey folks! I'm working on a CLI that forwards options from util.parseArgs to globby and encountered a runtime error when undefined is passed to the ignore option. While investigating the error I found that both the ignore and expandDirectories defaults are overridden when undefined is passed. I've included this same patch in my program so feel free to close this PR if the existing behavior is expected 👋