BackburnerJS / backburner.js

A rewrite of the Ember.js run loop as a generic microlibrary
MIT License
391 stars 80 forks source link

[BUGFIX master] properly cancel items which are added during flush #293

Closed bekzod closed 6 years ago

bekzod commented 6 years ago

~possible bugfix, targetQueues should be cleared only when _queue moved to _queueBeingFlushed else queueIndexes could be messed up https://github.com/BackburnerJS/backburner.js/blob/master/lib/backburner/queue.ts#L152~

bekzod commented 6 years ago

this is also affects 1.3.3

bekzod commented 6 years ago

my assumption was wrong, indexes in targetQueue could be messed when items are canceled or added during flush this fixes it and here is fix for 1.3.3 https://github.com/BackburnerJS/backburner.js/pull/295