-
Notifications
You must be signed in to change notification settings - Fork 2.2k
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
Return false for isFile for empty strings #2706
Conversation
Why are we passing |
As of Swift 5, corelibs-foundation crashes if you pass an empty string to `fileExists` https://github.com/apple/swift-corelibs-foundation/blob/cae5eaca63cd57f64a93b4d5de87a4ffc04466d5/Foundation/FileManager.swift#L2033
Generated by 🚫 Danger |
It looks like that's the default if no path is passed SwiftLint/Source/swiftlint/Helpers/CommonOptions.swift Lines 4 to 8 in dd39c43
|
Maybe that default should be a |
We can investigate and change, but I'm a bit afraid because we don't have unit tests for the |
Fix looks good to me. Added a changelog entry in 9cc97d6. Will merge when CI passes. |
As of Swift 5, corelibs-foundation crashes if you pass an empty string
to
fileExists
https://github.com/apple/swift-corelibs-foundation/blob/cae5eaca63cd57f64a93b4d5de87a4ffc04466d5/Foundation/FileManager.swift#L2033