firstOrNull

override fun firstOrNull(): T?

Get the first element or null if not found.

Return

T the first element or null


override fun firstOrNull(condition: T.() -> Boolean): T?

Get the first element by condition or null if not found

Return

T the first element or null

Parameters

condition

filter condition