-
Notifications
You must be signed in to change notification settings - Fork 795
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
Swift 4.1 / Xcode 9.3 Support #360
Conversation
Generated by 🚫 Danger |
Changed branch, sorry about that! I'm guessing Travis isn't configured for Swift 4.1 for the other errors. |
Will this still compile with Xcode 8 though? Some users have not upgraded yet and I'm wary of introducing changes that may break the build on non-latest tools. |
Would adding |
Instead of #if swift(>=4.1)
let receiptItems = nonCancelledReceiptsInfo.compactMap { ReceiptItem(receiptInfo: $0) }
#else
let receiptItems = nonCancelledReceiptsInfo.flatMap { ReceiptItem(receiptInfo: $0) }
#endif |
Thanks to Andrew Bennet for suggestion!
Cheers for updating! There's one typo in that commit though, using |
Ugh, my bad |
Hi @bizz84 - Can you explain what the Danger check is? Do tests need to be touched for every change? |
@mattbarker016 @AndrewBennet thanks for contributing! Don't worry about the Danger check. It's not very precise. |
Removed warnings from
flatMap
depreciation. Changed tocompactMap