mirror of
https://github.com/whoisclebs/lodash.git
synced 2026-02-06 01:47:48 +00:00
Fix dequeue.
This commit is contained in:
@@ -322,7 +322,7 @@ function onStart(error, res, body) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The `request.post` callback used by `check`.
|
* The `request.post` callback used by `Job#status`.
|
||||||
*
|
*
|
||||||
* @private
|
* @private
|
||||||
* @param {Object} [error] The error object.
|
* @param {Object} [error] The error object.
|
||||||
@@ -503,7 +503,8 @@ function run(platforms, onComplete) {
|
|||||||
});
|
});
|
||||||
|
|
||||||
var dequeue = function() {
|
var dequeue = function() {
|
||||||
while (queue.length && running++ < throttled) {
|
while (queue.length && (running < throttled)) {
|
||||||
|
running++;
|
||||||
queue.shift().start();
|
queue.shift().start();
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user