diff --git a/lib/index.ts b/lib/index.ts index 0e9bae59..0d469dba 100644 --- a/lib/index.ts +++ b/lib/index.ts @@ -116,7 +116,7 @@ export default class Backburner { if (this._autorun === null) { return; } this._autorun = null; - this.end(true /* fromAutorun */); + this._end(true /* fromAutorun */); }; let builder = this.options._buildPlatform || buildPlatform; @@ -151,7 +151,11 @@ export default class Backburner { return current; } - public end(fromAutorun = false) { + public end() { + this._end(false); + } + + private _end(fromAutorun: boolean) { let currentInstance = this.currentInstance; let nextInstance: DeferredActionQueues | null = null;