/** * Returns an effect that will produce the value of this effect, unless it * fails, in which case, it will produce the value of the specified effect. * * @tsplus static effect/core/io/Effect.Aspects orElseEither * @tsplus pipeable effect/core/io/Effect orElseEither */ export function orElseEither(that: LazyArg>) { return (self: Effect): Effect> => self.tryOrElse( that().map(Either.right), (a) => Effect.succeed(Either.left(a)) ) }