Skip to content

Commit d48ef1a

Browse files
committed
Freshen generated index.js file.
1 parent 06f25ed commit d48ef1a

File tree

1 file changed

+12
-12
lines changed

1 file changed

+12
-12
lines changed

dist/index.js

+12-12
Original file line numberDiff line numberDiff line change
@@ -7782,19 +7782,19 @@ function queueAsPromised (context, worker, _concurrency) {
77827782
}
77837783

77847784
function drained () {
7785-
if (queue.idle()) {
7786-
return new Promise(function (resolve) {
7787-
resolve()
7788-
})
7789-
}
7790-
7791-
var previousDrain = queue.drain
7792-
77937785
var p = new Promise(function (resolve) {
7794-
queue.drain = function () {
7795-
previousDrain()
7796-
resolve()
7797-
}
7786+
process.nextTick(function () {
7787+
if (queue.idle()) {
7788+
resolve()
7789+
} else {
7790+
var previousDrain = queue.drain
7791+
queue.drain = function () {
7792+
if (typeof previousDrain === 'function') previousDrain()
7793+
resolve()
7794+
queue.drain = previousDrain
7795+
}
7796+
}
7797+
})
77987798
})
77997799

78007800
return p

0 commit comments

Comments
 (0)