unwrapOrElse method

Future<S> unwrapOrElse(
  1. FutureOr<S> onError(
    1. F
    )
)

Implementation

Future<S> unwrapOrElse(FutureOr<S> Function(F) onError) {
  return mapOrElse(
    (err) {
      return onError(err);
    },
    (ok) {
      return ok;
    },
  );
}