propagateNull

fun <A : Any, B : Any> Pair<A?, B?>.propagateNull(): Pair<A, B>?(source)

When both items in pair are not null, returns non-nullable pair, otherwise returns null.