AsyncResult.err<E extends BaseError, T = never>(error: E): AsyncResult<T, E>
Creates a failed AsyncResult with the given error.
E extends BaseError
The type of the error
error: E
The error to wrap in an Err AsyncResult
AsyncResult<T, E>
AsyncResult in the Err state