remove console logs

This commit is contained in:
Silver Kuusik 2018-07-08 20:56:49 +02:00 committed by GitHub
parent 34352bf1a6
commit 58fcaa8245
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -40,7 +40,6 @@ Sumorobot.prototype.connect = function() {
}; };
// When the WebSocket closes // When the WebSocket closes
this.websocket.onclose = function(evt) { this.websocket.onclose = function(evt) {
console.log("INFO websocket disconnected");
// Clear the pinging // Clear the pinging
clearInterval(self.watchdogTimer); clearInterval(self.watchdogTimer);
// Try to recnnect to the sumorobot // Try to recnnect to the sumorobot
@ -72,10 +71,8 @@ Sumorobot.prototype.send = function(msg, val) {
// https://developer.mozilla.org/en-US/docs/Web/API/WebSocket // https://developer.mozilla.org/en-US/docs/Web/API/WebSocket
if (this.websocket.readyState == 1) { if (this.websocket.readyState == 1) {
if (val === 'undefined') { if (val === 'undefined') {
console.log("no val")
this.websocket.send(`{"to": "sumo-${this.robotId}@00000514", "cmd": "${msg}"}`); this.websocket.send(`{"to": "sumo-${this.robotId}@00000514", "cmd": "${msg}"}`);
} else { } else {
console.log("val")
this.websocket.send(`{"to": "sumo-${this.robotId}@00000514", "cmd": "${msg}", "val": "${val}"}`); this.websocket.send(`{"to": "sumo-${this.robotId}@00000514", "cmd": "${msg}", "val": "${val}"}`);
} }
} }