/*global Promise:true*/
var Promise = require('bluebird');
var workQueue = {
    queue: [],
    drain: function () {
        this.queue.forEach(function (fn) {
            fn();
        });
        this.queue = [];
    }
};

var scheduler = Promise.setScheduler(function (fn) {
    workQueue.queue.push(fn);
    scheduler(function () {
        workQueue.drain();
    });
});

module.exports = workQueue;

@@ -52,16 +52,17 @@
 bird');%0A
+%0A
 var work
@@ -370,16 +370,294 @@
 );%0A%7D);%0A%0A
+%0Avar _notifyUnhandledRejection = Promise.prototype._notifyUnhandledRejection;%0APromise.prototype._notifyUnhandledRejection = function () %7B%0A    var that = this;%0A    var args = arguments;%0A    scheduler(function () %7B%0A        _notifyUnhandledRejection.apply(that, args);%0A    %7D);%0A%7D;%0A%0A
 module.e

Fix that we was throwing unhandled rejections