From 1752ab93e0a7a565ab7cbf2b0c81e52191abb2d0 Mon Sep 17 00:00:00 2001 From: Ranlvor Date: Sun, 2 Sep 2018 03:50:02 +0200 Subject: [PATCH] ; all the things --- config/rzl/index.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/config/rzl/index.js b/config/rzl/index.js index 1669471..a8c4ecb 100644 --- a/config/rzl/index.js +++ b/config/rzl/index.js @@ -149,11 +149,11 @@ const config: Config = { state: { name: "/service/ultimaker/job", type: (msg) => { - const json = JSON.parse(msg.toString()) + const json = JSON.parse(msg.toString()); if(!json || !json["time_elapsed"] || !json["time_total"]) { - return "" + return ""; } else { - const secondsLeft = json["time_total"] - json["time_elapsed"] + const secondsLeft = json["time_total"] - json["time_elapsed"]; return new Date(secondsLeft * 1000).toISOString().substr(11, 8); } }