effect-io-ai

Package: effect
Module: Stream

Stream.someOrFail

Extracts the optional value, or fails with the given error ā€˜e’.

Signature

declare const someOrFail: { <E2>(error: LazyArg<E2>): <A, E, R>(self: Stream<Option.Option<A>, E, R>) => Stream<A, E2 | E, R>; <A, E, R, E2>(self: Stream<Option.Option<A>, E, R>, error: LazyArg<E2>): Stream<A, E | E2, R>; }

Source

Since v2.0.0