mapErrorCause<C> method

Effect<E, C, R> mapErrorCause<C>(
  1. C f(
    1. Cause<L> l
    )
)

{@category mapping}

Implementation

Effect<E, C, R> mapErrorCause<C>(C Function(Cause<L> l) f) => Effect.from(
      (context) => _unsafeRun(context).then(
        (exit) => switch (exit) {
          Left(value: final cause) => Left(Failure(f(cause))),
          Right(value: final value) => Right(value),
        },
      ),
    );