markormesher / android-fab

Floating action button (FAB) for Android with speed-dial menu functionality
Apache License 2.0
211 stars 29 forks source link

Crash when FloatingActionButton.setOnSpeedDialMenuCloseListener() get's null as parameter #26

Closed tihomirleka closed 6 years ago

tihomirleka commented 6 years ago

Hi,

I just updated from Java to Kotlin (latest) version of the library and my app crashes when I try to pass null to FloatingActionButton.setOnSpeedDialMenuCloseListener() method.

I get the following error

Fatal Exception: java.lang.IllegalArgumentException: Parameter specified as non-null is null: method kotlin.jvm.internal.Intrinsics.checkParameterIsNotNull, parameter listener
       at uk.co.markormesher.android_fab.FloatingActionButton.setOnSpeedDialMenuCloseListener(FloatingActionButton.kt)

I don't know Kotlin so I'm not sure what's the problem.

markormesher commented 6 years ago

Hey @tihomirleka - thanks for flagging this! I can see the problem; I'll release a fix shortly.

markormesher commented 6 years ago

Fixed in v2.2.1 - let me know if you have any other issues! 👍

tihomirleka commented 6 years ago

Just tested it. No crash. Thanks