mapToRightOr

fun <L, R> <Error class: unknown class><Either<L, R>>.mapToRightOr(value: R): <Error class: unknown class><R>

map Flow> to the Flow.

Parameters

value

that Flow emits if original Either.isLeft = true

Example1: flowOf(Either.Right(1)).mapToRightOr(0) will emit 1

Example2: flowOf(Either.Left("Error")).mapToRightOr(0) will emit 0