From 30440596520a2ba7b7c2edb687d087ea3da79d95 Mon Sep 17 00:00:00 2001 From: Guangcong Luo Date: Thu, 9 May 2013 21:06:10 -0700 Subject: [PATCH] Don't send empty lines --- js/client-chat.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/js/client-chat.js b/js/client-chat.js index 5f0a6cdad..48368171b 100644 --- a/js/client-chat.js +++ b/js/client-chat.js @@ -51,6 +51,10 @@ e.stopPropagation(); var text; if ((text = this.$chatbox.val())) { + if (!$.trim(text)) { + this.$chatbox.val(''); + return; + } this.tabComplete.reset(); // this.chatHistory.push(text); text = this.parseCommand(text);