Merge pull request #413 from battleroy/battleroy/observable-extension-cancellation-token-forwarding

Fix cancellation token forwarding
master
Yoshifumi Kawai 2022-10-12 10:53:30 +09:00 committed by GitHub
commit ee54559532
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 2 deletions

View File

@ -133,7 +133,7 @@ namespace Cysharp.Threading.Tasks
{
var self = (ToUniTaskObserver<T>)state;
self.disposable.Dispose();
self.promise.TrySetCanceled();
self.promise.TrySetCanceled(self.cancellationToken);
}
public void OnNext(T value)
@ -203,7 +203,7 @@ namespace Cysharp.Threading.Tasks
{
var self = (FirstValueToUniTaskObserver<T>)state;
self.disposable.Dispose();
self.promise.TrySetCanceled();
self.promise.TrySetCanceled(self.cancellationToken);
}
public void OnNext(T value)