Skip to content

updates for Swift 4#17

Open
mathbeat wants to merge 1 commit intosasojadrovski:masterfrom
newellxo:master
Open

updates for Swift 4#17
mathbeat wants to merge 1 commit intosasojadrovski:masterfrom
newellxo:master

Conversation

@mathbeat
Copy link
Copy Markdown

This commit fixes the build errors associated with Swift 4.

@lucaventura
Copy link
Copy Markdown

lucaventura commented Nov 3, 2017

@mathbeat Instead of returning a duplicate colors array to resolve the overlapping access error you can simply force unwrap colors since it is already force unwrapped in the if check:

 if colors!.count == 1 {
 -            colors!.append((colors?.first)!)
}

Can confirm this doesn't cause any crashes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants