foldHttpError

inline fun <T, R> KrosstalkResult.SuccessOrHttpError<T>.foldHttpError(onSuccess: (KrosstalkResult.Success<T>) -> R, onHttpError: (KrosstalkResult.HttpError) -> R): R

Get a value depending on the type of result.

Sources

Link copied to clipboard