Skip to content

Commit

Permalink
fix: catch pause errors when closing
Browse files Browse the repository at this point in the history
  • Loading branch information
manast committed Oct 14, 2023
1 parent 4d197e8 commit ccb6cc7
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions lib/queue.js
Expand Up @@ -593,6 +593,7 @@ Queue.prototype.close = function(doNotWaitJobs) {
isReady = false;
})
.then(() => isReady && this.pause(true, doNotWaitJobs))
.catch(() => void 0) // Ignore possible error from pause
.finally(() => this._clearTimers())
.then(() => {
if (!this.childPool) {
Expand Down

0 comments on commit ccb6cc7

Please sign in to comment.