lib/Revenant.js
function (task, argument, callback) {
        var self = this;
        var queueArgument = {
            task: task,
            argument: argument
        };

        return promiseOrCallback(callback, function (resolve, reject) {
            self.taskQueue.push(queueArgument, function (error, result) {
                if (error) {
                    reject(error);
                } else {
                    resolve(result);
                }
            });
        });
    }
function (task, argument, callback) {
        var self = this;
        var queueArgument = {
            task: task,
            argument: argument
        };

        return promiseOrCallback(callback, function (resolve, reject) {
            self.taskQueue.push(queueArgument, function (error, result) {
                if (error) {
                    reject(error);
                } else {
                    resolve(result);
                }
            });
        });
    }
function ( task , argument , callback ) { var self = this ; var queueArgument = { task : task , argument : argument } ; return promiseOrCallback ( callback , function ( resolve , reject ) { self . taskQueue . push ( queueArgument , function ( error , result ) { if ( error ) { reject ( error ) ; } else { resolve ( result ) ; } } ) ; } ) ; }
Private helper function to push a task
@param task
@param argument
@param callback
@returns {Promise}
@private
Private helper function to push a task