mirror of https://github.com/Cysharp/UniTask
Fix ToCancellationToken linkToken
parent
7718d345c8
commit
7432c0073a
|
@ -33,7 +33,7 @@ namespace Cysharp.Threading.Tasks
|
|||
var cts = new CancellationTokenSource();
|
||||
ToCancellationTokenCore(task, cts).Forget();
|
||||
|
||||
return CancellationTokenSource.CreateLinkedTokenSource(linkToken).Token;
|
||||
return CancellationTokenSource.CreateLinkedTokenSource(cts.Token, linkToken).Token;
|
||||
}
|
||||
|
||||
public static CancellationToken ToCancellationToken<T>(this UniTask<T> task)
|
||||
|
|
Loading…
Reference in New Issue