tryCatchK2<A, B, S, C, L, R> function

StateReaderTaskEither<S, C, L, R> Function(A a, B b) tryCatchK2<A, B, S, C, L, R>(
  1. FutureOr<R> task(
    1. A a,
    2. B b
    ),
  2. L onError(
    1. dynamic err,
    2. StackTrace stackTrace
    )
)

A variant of tryCatch that accepts two external parameters.

Implementation

StateReaderTaskEither<S, C, L, R> Function(A a, B b)
    tryCatchK2<A, B, S, C, L, R>(
  FutureOr<R> Function(A a, B b) task,
  L Function(dynamic err, StackTrace stackTrace) onError,
) =>
        (a, b) => tryCatch(() => task(a, b), onError);