From 74dc698d0a25b069b8bd026a4dbcda998d71389d Mon Sep 17 00:00:00 2001 From: DJ2LS Date: Wed, 17 May 2023 09:06:07 +0000 Subject: [PATCH] Prettified Code! --- gui/preload-chat.js | 24 ++++++++++++++---------- gui/sock.js | 2 +- 2 files changed, 15 insertions(+), 11 deletions(-) diff --git a/gui/preload-chat.js b/gui/preload-chat.js index b87370bc..b91f6b49 100644 --- a/gui/preload-chat.js +++ b/gui/preload-chat.js @@ -482,8 +482,8 @@ window.addEventListener("DOMContentLoaded", () => { var tnc_command = "broadcast"; var message_type = "broadcast_transmit"; - // slice uuid for reducing overhead - uuid = uuid.slice(-4); + // slice uuid for reducing overhead + uuid = uuid.slice(-4); let Data = { command: tnc_command, @@ -2322,13 +2322,14 @@ function getSetUserInformation(selected_callsign) { if (selected_callsign.startsWith("BC-")) { var userIcon = defaultGroupIcon; - document.getElementById("chatModuleMessage").setAttribute("maxlength", 16); - + document + .getElementById("chatModuleMessage") + .setAttribute("maxlength", 16); } else { var userIcon = defaultUserIcon; - document.getElementById("chatModuleMessage").setAttribute("maxlength", 524288); - - + document + .getElementById("chatModuleMessage") + .setAttribute("maxlength", 524288); } document.getElementById("user-image-" + selected_callsign).src = @@ -2390,12 +2391,15 @@ function getSetUserInformation(selected_callsign) { console.log(err); if (selected_callsign.startsWith("BC-")) { - document.getElementById("chatModuleMessage").setAttribute("maxlength", 16); + document + .getElementById("chatModuleMessage") + .setAttribute("maxlength", 16); var userIcon = defaultGroupIcon; } else { var userIcon = defaultUserIcon; - document.getElementById("chatModuleMessage").setAttribute("maxlength", 524288); - + document + .getElementById("chatModuleMessage") + .setAttribute("maxlength", 524288); } // Callsign list elements diff --git a/gui/sock.js b/gui/sock.js index 80784667..ec3893c9 100644 --- a/gui/sock.js +++ b/gui/sock.js @@ -866,7 +866,7 @@ exports.sendBroadcastChannel = function (channel, data_out, uuid) { split_char + data_out ); - console.log(data.length) + console.log(data.length); let payload = data; command = '{"type" : "fec", "command" : "transmit", "mode": "datac4", "wakeup": "True", "payload" : "' +