From 7b054b235db54603d43a852efc366cc74f7b9972 Mon Sep 17 00:00:00 2001 From: rainbow napkin Date: Fri, 26 Dec 2025 12:42:40 -0500 Subject: [PATCH] Server now prevents empty chats. --- src/app/channel/chatHandler.js | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/app/channel/chatHandler.js b/src/app/channel/chatHandler.js index bc1e751..218f561 100644 --- a/src/app/channel/chatHandler.js +++ b/src/app/channel/chatHandler.js @@ -212,6 +212,12 @@ class chatHandler{ * @param {chat} chat - Chat Object representing the message to broadcast to the given channel */ relayChatObject(chan, chat){ + //If we have an empty chat + if(chat.msg.length <= 0){ + //Drop it + return; + } + //Send out chat this.server.io.in(chan).emit("chatMessage", chat);