Is it on purpose that `Flow` has `singleOrNull` bu...
# coroutines
d
Is it on purpose that
Flow
has
singleOrNull
but not
firstOrNull
?
d
Considering flows are ordered, they would do the exact same thing, no?
d
Single throws if there's more than one emission
d
You're right.
b
Probably more along the lines that there wasn't a use case requested and therefore wasn't added during the preview :)
Looks like it was intentional due to lack of use case given during the preview https://github.com/Kotlin/kotlinx.coroutines/issues/1078
👍 1
BUT thanks to the world of OSS -- you can 👍 it here: https://github.com/Kotlin/kotlinx.coroutines/pull/1796
d
And thanks for the PR 😉!