lib/queue.js
function Queue (q) {
  events.EventEmitter.call(this);
  var self = this;

  this.q = q && q.process ? q : kue.createQueue();
  this.q.process('message', function (message, done) {
    self.emit('message', message);
    done();
  });
}
function Queue (q) {
  events.EventEmitter.call(this);
  var self = this;

  this.q = q && q.process ? q : kue.createQueue();
  this.q.process('message', function (message, done) {
    self.emit('message', message);
    done();
  });
}
/*
We use a queue to process events when we must handle the events sequentially