This commit is contained in:
Ell 2021-03-21 02:02:11 +01:00
parent 0de8a0dd2d
commit 0e5b571590
2 changed files with 2 additions and 2 deletions

View file

@ -132,7 +132,7 @@ namespace Coroutine {
var coroutines = this.GetOutstandingCoroutines(evt);
if (coroutines.Count > 0) {
coroutines.RemoveWhere(c => {
var list = c.IsWaitingForEvent ? this.GetEventCoroutines(c.Event, true) : this.tickingCoroutines;
var list = evt ? this.GetEventCoroutines(c.Event, true) : this.tickingCoroutines;
var position = list.BinarySearch(c);
list.Insert(position < 0 ? ~position : position, c);
return true;