flatMapOrElse<U, F> method
Maps Result<T, E> to Result<U, E>, leaving an Err
value untouched.
Allows chaining Results without nesting them.
Implementation
Result<U, F> flatMapOrElse<U, F>(
Result<U, F> Function(T) f,
Result<U, F> Function(E) e,
) =>
isOk ? f(_value) : e(_error);