From ceb107f43bc2832448dfc21c5f39f8049f0ab158 Mon Sep 17 00:00:00 2001 From: Iuri Matias Date: Mon, 26 Feb 2018 17:44:09 -0500 Subject: [PATCH] send logs to ws --- lib/modules/webserver/backend/index.html | 33 ++++++++++-------------- lib/modules/webserver/server.js | 3 +-- 2 files changed, 14 insertions(+), 22 deletions(-) diff --git a/lib/modules/webserver/backend/index.html b/lib/modules/webserver/backend/index.html index 43288c26..3deda358 100644 --- a/lib/modules/webserver/backend/index.html +++ b/lib/modules/webserver/backend/index.html @@ -1,29 +1,22 @@ Welcome to Embark! diff --git a/lib/modules/webserver/server.js b/lib/modules/webserver/server.js index 6cf7775a..5fafb6de 100644 --- a/lib/modules/webserver/server.js +++ b/lib/modules/webserver/server.js @@ -69,8 +69,7 @@ class Server { this.app.ws('/logs', function(ws, req) { self.events.on("log", function(logLevel, logMsg) { - console.dir("got message " + logMsg); - ws.send(logMsg); + ws.send(logMsg.stripColors); }); ws.on('message', function(msg) { console.dir("got message");