Fix an warning in nodejs v7

This commit is contained in:
Khaos Tian
2016-11-29 18:42:17 -08:00
parent 69e3ed5ee4
commit f17fe59590

View File

@@ -178,7 +178,7 @@ BridgeSetupSession.prototype.handleManageAccessory = function(request) {
BridgeSetupSession.prototype.sendResponse = function(response) { BridgeSetupSession.prototype.sendResponse = function(response) {
if (this.validSession) { if (this.validSession) {
var serializedReponse = JSON.stringify(response); var serializedReponse = JSON.stringify(response);
var respData = Buffer(serializedReponse).toString('base64'); var respData = new Buffer(serializedReponse).toString('base64');
this.lastResponse = respData; this.lastResponse = respData;
setTimeout(function() { setTimeout(function() {
this.controlChar.setValue(respData); this.controlChar.setValue(respData);