Skip to content

Commit

Permalink
https://github.com/apocas/dockerode/issues/171
Browse files Browse the repository at this point in the history
  • Loading branch information
apocas committed Mar 10, 2017
1 parent df1efec commit 1c65e2d
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions lib/docker.js
Original file line number Diff line number Diff line change
Expand Up @@ -1236,7 +1236,7 @@ Docker.prototype.run = function(image, cmd, streamo, createOptions, startOptions
if (typeof arguments[arguments.length - 1] === 'function') {
return this.runCallback(image, cmd, streamo, createOptions, startOptions, callback);
} else {
return this.runAsync(image, cmd, streamo, createOptions, startOptions);
return this.runPromise(image, cmd, streamo, createOptions, startOptions);
}
};

Expand Down Expand Up @@ -1321,7 +1321,7 @@ Docker.prototype.runCallback = function(image, cmd, streamo, createOptions, star
return hub;
};

Docker.prototype.runAsync = function(image, cmd, streamo, createOptions, startOptions) {
Docker.prototype.runPromise = function(image, cmd, streamo, createOptions, startOptions) {
var self = this;

createOptions = createOptions || {};
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "dockerode",
"description": "Docker Remote API module.",
"version": "2.3.5",
"version": "2.3.6",
"author": "Pedro Dias <[email protected]>",
"maintainers": [
"apocas <[email protected]>"
Expand Down
2 changes: 1 addition & 1 deletion test/promises.js
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ describe("#promises", function() {
});
});

it("should runAsync a command", function(done) {
it("should runPromise a command", function(done) {
this.timeout(30000);

docker.run(testImage, ['bash', '-c', 'uname -a'], process.stdout).then(function(container) {
Expand Down

0 comments on commit 1c65e2d

Please sign in to comment.