Minor fix for messages with spaces only

This commit is contained in:
calzoneman 2014-08-29 15:49:32 -05:00
parent 484b695965
commit 7002874bbb

View file

@ -120,7 +120,7 @@ ChatModule.prototype.handleChatMsg = function (user, data) {
data.msg = data.msg.substring(0, 240).replace(/[\x00-\x08\x0a-\x1f]+/g, " "); data.msg = data.msg.substring(0, 240).replace(/[\x00-\x08\x0a-\x1f]+/g, " ");
// Disallow blankposting // Disallow blankposting
if (!data.msg) { if (!data.msg.trim()) {
return; return;
} }