onFailure

inline fun onFailure(block: (Throwable) -> Unit): RestResult<T>(source)

Runs the given block on the encapsulated Throwable exception if this instance represents failure, and the exception is not ignored.

Returns the original RestResult unchanged.