-
Notifications
You must be signed in to change notification settings - Fork 4.2k
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
use asSingle() #1654
Comments
I looked at the code for asSingle() , |
It is required to call take(1) on PublishSubject before calling asSingle:
This is unexpected and may cause bugs. |
great! save my time |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
let a = PublishSubject()
a.asSingle().subscribe(onSuccess: { (_) in
print("asasaa")
}) { (error) in
}.disposed(by: self.disposeBag)
a.onNext(1)
When I call the code above, there is no print.
Is the asSingle() method using errors?
The text was updated successfully, but these errors were encountered: