code: function getLength(queue, queuex) {
    // if previous call didn't execute all callbacks
    return queuex.length ?
      // reprioritize the queue putting those in front
      queue.unshift.apply(queue, queuex) :
      queue.length;
  }
docs: return the right queue length to consider re-prioritizing scheduled callbacks