Skip to content

Commit

Permalink
add #startAll and #stopAll
Browse files Browse the repository at this point in the history
  • Loading branch information
alexbepple committed Jan 22, 2015
1 parent f3fa191 commit 1692436
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions lib/transmission.js
Expand Up @@ -228,6 +228,13 @@ Transmission.prototype.stop = function(ids, callback) {
return this;
};

Transmission.prototype.stopAll = function(callback) {
this.callServer({
method : this.methods.torrents.stop
}, callback);
return this;
};

Transmission.prototype.start = function(ids, callback) {
ids = Array.isArray(ids) ? ids : [ids];
this.callServer({
Expand All @@ -240,6 +247,13 @@ Transmission.prototype.start = function(ids, callback) {
return this;
};

Transmission.prototype.startAll = function(callback) {
this.callServer({
method : this.methods.torrents.start
}, callback);
return this;
};

Transmission.prototype.startNow = function(ids, callback) {
ids = Array.isArray(ids) ? ids : [ids];
this.callServer({
Expand Down

0 comments on commit 1692436

Please sign in to comment.