orElse<L1> method

  1. @override
Either<L1, R> orElse<L1>(
  1. Either<L1, R> onLeft(
    1. L l
    )
)
override

If this Either is Left, return the result of onLeft.

Used to recover from errors, so that when this value is Left you try another function that returns an Either.

Implementation

@override
Either<L1, R> orElse<L1>(Either<L1, R> Function(L l) onLeft) =>
    Either.of(_value);