mirror of https://github.com/Cysharp/UniTask
Add to the code that I forgot to write
parent
dfe5ee43c2
commit
06283f0ffb
|
@ -241,6 +241,10 @@ namespace Cysharp.Threading.Tasks
|
|||
{
|
||||
TryReturn();
|
||||
}
|
||||
else
|
||||
{
|
||||
TaskTracker.RemoveTracking(this);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -461,6 +465,7 @@ namespace Cysharp.Threading.Tasks
|
|||
result.predicate = predicate;
|
||||
result.argument = argument;
|
||||
result.cancellationToken = cancellationToken;
|
||||
result.cancelImmediately = cancelImmediately;
|
||||
|
||||
if (cancelImmediately && cancellationToken.CanBeCanceled)
|
||||
{
|
||||
|
@ -491,6 +496,10 @@ namespace Cysharp.Threading.Tasks
|
|||
{
|
||||
TryReturn();
|
||||
}
|
||||
else
|
||||
{
|
||||
TaskTracker.RemoveTracking(this);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue