From db1b7352f3c7233b98d47b4fd6617fe07cdab618 Mon Sep 17 00:00:00 2001 From: stonedDiscord Date: Mon, 10 Apr 2023 20:44:07 +0200 Subject: spammy logging --- webAO/client.ts | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) (limited to 'webAO') diff --git a/webAO/client.ts b/webAO/client.ts index 566334e..e5c5e2b 100644 --- a/webAO/client.ts +++ b/webAO/client.ts @@ -38,6 +38,7 @@ export const UPDATE_INTERVAL = 60; */ export let oldLoading = false; export const setOldLoading = (val: boolean) => { + console.warn("old loading set to "+val) oldLoading = val } @@ -261,7 +262,6 @@ class Client extends EventEmitter { } const packet_list = in_data.split("%"); - console.log(packet_list) for (var packet of packet_list) { let f_contents; @@ -280,12 +280,14 @@ class Client extends EventEmitter { } // Take the first arg as the command const command = f_contents[0]; - console.log(command) - // The rest is contents of the packet - packetHandler.has(command) - ? packetHandler.get(command)(f_contents) - : console.warn(`Invalid packet header ${command}`); - }; + if(command!=="") + { + // The rest is contents of the packet + packetHandler.has(command) + ? packetHandler.get(command)(f_contents) + : console.warn(`Invalid packet header ${command}`); + }; + } } -- cgit