mirror of https://github.com/Cysharp/UniTask
Forget ignored task
parent
9057452c86
commit
e0465c6c2c
|
@ -201,6 +201,7 @@ namespace Cysharp.Threading.Tasks
|
|||
|
||||
if (cancellationToken.IsCancellationRequested)
|
||||
{
|
||||
task.Forget();
|
||||
return UniTask.FromCanceled(cancellationToken);
|
||||
}
|
||||
|
||||
|
@ -224,6 +225,7 @@ namespace Cysharp.Threading.Tasks
|
|||
|
||||
if (cancellationToken.IsCancellationRequested)
|
||||
{
|
||||
task.Forget();
|
||||
return UniTask.FromCanceled<T>(cancellationToken);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue