Skip to content

Commit

Permalink
Merge pull request thibauts#10 from guerrerocarlos/master
Browse files Browse the repository at this point in the history
fixes setVolume
  • Loading branch information
thibauts committed Oct 22, 2014
2 parents 2765729 + 3a5a097 commit 24e7527
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions lib/controllers/receiver.js
Original file line number Diff line number Diff line change
Expand Up @@ -33,11 +33,11 @@ ReceiverController.prototype.getStatus = function(callback) {
};

ReceiverController.prototype.getAppAvailability = function(appId, callback) {
var data = {
type: 'GET_APP_AVAILABILITY',
var data = {
type: 'GET_APP_AVAILABILITY',
appId: Array.isArray(appId) ? appId : [appId]
};

this.request(data, function(err, response) {
if(err) return callback(err);
callback(null, response.availability);
Expand All @@ -59,9 +59,9 @@ ReceiverController.prototype.stop = function(sessionId, callback) {
};

ReceiverController.prototype.setVolume = function(volume, callback) {
var data = {
type: 'SET_VOLUME',
volume: volume
var data = {
type: 'SET_VOLUME',
volume: {level: volume}
};

this.request(data, function(err, response) {
Expand All @@ -84,4 +84,4 @@ ReceiverController.prototype.getSessions = function(callback) {
});
};

module.exports = ReceiverController;
module.exports = ReceiverController;

0 comments on commit 24e7527

Please sign in to comment.