summaryrefslogtreecommitdiff
authorNathan Zorn <nathan.zorn@gmail.com>2010-06-11 14:48:39 (GMT)
committer Nathan Zorn <nathan.zorn@gmail.com>2010-06-11 14:48:39 (GMT)
commit44d54912385ab6d124ae284713fca1ec8376bb34 (patch)
tree8f2d5fccff6c3566c9c2dd11a15b0251154fe272
parente9b00b10d494d120cd365f4686788ac13ee635b5 (diff)
downloadspeeqe-master.zip
speeqe-master.tar.gz
speeqe-master.tar.bz2
prevent blank messagesmaster
-rw-r--r--speeqewebclient/scripts/chat.js5
1 files changed, 5 insertions, 0 deletions
diff --git a/speeqewebclient/scripts/chat.js b/speeqewebclient/scripts/chat.js
index 81a3d34..b76ee0f 100644
--- a/speeqewebclient/scripts/chat.js
+++ b/speeqewebclient/scripts/chat.js
@@ -34,6 +34,11 @@ Speeqe.Chat.prototype = {
},
//private function to send xmpp message
_buildAndSendMessage: function(to, message, type) {
+ // don't send blank messages
+ if ($.trim(message) === "")
+ {
+ return;
+ }
if (type !== "groupchat")
{
var msgid = this._connection.getUniqueId();