toFutureVoid<L> function

Future<void> Function(TaskEither<L, dynamic> taskEither) toFutureVoid<L>(
  1. void onLeft(
    1. L value
    )
)

Convert a TaskEither into a Future<void>, that runs the side effect on Left.

Implementation

Future<void> Function(TaskEither<L, dynamic> taskEither) toFutureVoid<L>(
  void Function(L value) onLeft,
) =>
    (te) => Future.sync(te.chain(fold(onLeft, (_) {})).call);