safe rc off as well as on values

This commit is contained in:
Shannon Sterz 2016-02-17 14:13:46 +01:00
parent 395201c801
commit 21513c81f2

View file

@ -30,8 +30,8 @@ RC.prototype.delete = function(id, callback) {
}
RC.prototype.add = function(rc, callback) {
// var rc = {tristate: bool, value: FF00..., name:'Switch name'};
connection.query('INSERT INTO rc_switches SET ?', rc, callback);
// var rc = {tristate:bool, on_value:"FF00...", off_value:"FF00...", name:"Switch name"};
var query = connection.query('INSERT INTO rc_switches SET ?', rc, callback);
}
module.exports = RC;