match<B> method
Pattern matching to convert a ReaderTaskEither to a ReaderTask.
Execute onLeft
when running this ReaderTaskEither returns a Left.
Otherwise execute onRight
.
Implementation
ReaderTask<E, B> match<B>(
B Function(L left) onLeft,
B Function(R right) onRight,
) =>
ReaderTask(
(env) async => (await run(env)).match(
onLeft,
onRight,
),
);