-
Notifications
You must be signed in to change notification settings - Fork 7.6k
1.x: Feature Request Observable.firstOrDefaultSingle #4277
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
What's wrong with |
Or |
Nothing is wrong with that, I'm right now using |
I don't like that it conflates two concepts: taking the empty stream and ensuring it's non-empty but also transforming the type from Observable to Single. |
Closing since if this type of suggestion would be approved (basically transforming Observable in any way into one that only emits one item and then converts itself into Single a lot of other operators would need to get the |
How do you guys feel about an overload that is named something along the lines of
Observable.firstOrDefaultSingle
and basically does the same asObservable.firstOrDefault
with the difference of returning aSingle<T>
instead ofObservable<T>
?Edit: Could also maybe be called
firstOrDefaultAsSingle
The text was updated successfully, but these errors were encountered: