We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent e2eac2a commit 33213b5Copy full SHA for 33213b5
packages/action-listener-middleware/src/job.ts
@@ -290,15 +290,18 @@ export class Job<T> implements JobHandle {
290
) {
291
const childrenCopy = [...this._children]
292
const skipSet = new Set(skipChildren)
293
+ const remainingChildren: typeof this._children = []
294
childrenCopy.forEach((job) => {
- if (!skipSet.has(job)) {
295
+ if (skipSet.has(job)) {
296
+ remainingChildren.push(job)
297
+ } else {
298
job.cancel(
299
reason ??
300
new JobCancellationException(JobCancellationReason.JobCancelled)
301
)
302
}
303
})
- this._children = []
304
+ this._children = remainingChildren
305
306
307
private _addChild(child: Job<any>) {
0 commit comments