ifError

inline fun <V, E> Result<V, E>.ifError(onError: (E) -> Unit)

Kotlin convenience method: invoke the callback if the result is an error.