Skip to content

Commit

Permalink
Merge pull request #413 from battleroy/battleroy/observable-extension…
Browse files Browse the repository at this point in the history
…-cancellation-token-forwarding

Fix cancellation token forwarding
  • Loading branch information
neuecc committed Oct 12, 2022
2 parents e999268 + 4a72ec2 commit ee54559
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ static void OnCanceled(object state)
{
var self = (ToUniTaskObserver<T>)state;
self.disposable.Dispose();
self.promise.TrySetCanceled();
self.promise.TrySetCanceled(self.cancellationToken);
}

public void OnNext(T value)
Expand Down Expand Up @@ -203,7 +203,7 @@ static void OnCanceled(object state)
{
var self = (FirstValueToUniTaskObserver<T>)state;
self.disposable.Dispose();
self.promise.TrySetCanceled();
self.promise.TrySetCanceled(self.cancellationToken);
}

public void OnNext(T value)
Expand Down

0 comments on commit ee54559

Please sign in to comment.