-
Notifications
You must be signed in to change notification settings - Fork 699
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
Crash in shortestColumnIndexInSection #172
Comments
Not knowing what the issue is, plus I haven't used the module yet the code from above could be swiftified to (almost never ever use force-cast or IUO's): // This is far more safe than the original code
if let height = obj as? Float, height < shortestHeight {
shortestHeight = height
index = idx
} Btw. fix the typo in |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi I try to use the example app with Swift3 and i face the crash issue in
App getting crash in this line.
let height = obj as! Float
When i try to check for that nil in the above function,(i.e)
let height = obj as? Float if (height != nil && height<shorestHeight){ shorestHeight = height! index = idx }
My collectionview layout is in single coloum (i.e instead of two column it comes in single column)
Crash
![screen shot 2017-05-11 at 12 28 41 pm](https://cloud.githubusercontent.com/assets/5052940/25936442/670f1574-3645-11e7-9b58-c71e7149c9d0.png)
The text was updated successfully, but these errors were encountered: