Small cleanup
This commit is contained in:
@@ -6,6 +6,6 @@ fun Float.floor(): Int = floor(this).toInt()
|
||||
|
||||
fun Double.floor(): Int = floor(this).toInt()
|
||||
|
||||
fun Int.nullIfZero() = if (this == 0) null else this
|
||||
fun Int.nullIfZero() = takeUnless { it == 0 }
|
||||
|
||||
fun Long.nullIfZero() = if (this == 0L) null else this
|
||||
fun Long.nullIfZero() = takeUnless { it == 0L }
|
||||
|
||||
Reference in New Issue
Block a user