We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent b26982a commit 8f1cafdCopy full SHA for 8f1cafd
src/asynciterable/merge.ts
@@ -42,8 +42,10 @@ export class MergeAsyncIterable<T> extends AsyncIterableX<T> {
42
nexts[index] = <Promise<MergeResult<IteratorResult<T>>>>NEVER_PROMISE;
43
active--;
44
} else {
45
+ const iterator$ = iterators[index];
46
+ nexts[index] = <Promise<MergeResult<IteratorResult<T>>>>NEVER_PROMISE;
47
yield value$;
- nexts[index] = wrapPromiseWithIndex(iterators[index].next(), index);
48
+ nexts[index] = wrapPromiseWithIndex(iterator$.next(), index);
49
}
50
51
0 commit comments