Ver código fonte

Merge pull request #468 from 1st8/master

Fix [object Object] being sometimes shown as status
JC Brand 10 anos atrás
pai
commit
64878ec6e0
2 arquivos alterados com 2 adições e 1 exclusões
  1. 1 1
      converse.js
  2. 1 0
      docs/CHANGES.rst

+ 1 - 1
converse.js

@@ -4457,7 +4457,7 @@
                     if ((converse.connection.jid !== jid)&&(presence_type !== 'unavailable')) {
                     if ((converse.connection.jid !== jid)&&(presence_type !== 'unavailable')) {
                         // Another resource has changed its status, we'll update ours as well.
                         // Another resource has changed its status, we'll update ours as well.
                         converse.xmppstatus.save({'status': chat_status});
                         converse.xmppstatus.save({'status': chat_status});
-                        if (status_message.length) { converse.xmppstatus.save({'status_message': status_message}); }
+                        if (status_message.length) { converse.xmppstatus.save({'status_message': status_message.text()}); }
                     }
                     }
                     return;
                     return;
                 } else if (($presence.find('x').attr('xmlns') || '').indexOf(Strophe.NS.MUC) === 0) {
                 } else if (($presence.find('x').attr('xmlns') || '').indexOf(Strophe.NS.MUC) === 0) {

+ 1 - 0
docs/CHANGES.rst

@@ -5,6 +5,7 @@ Changelog
 ------------------
 ------------------
 
 
 * #462 Fix MUC rooms with names containing special characters not working [1st8]
 * #462 Fix MUC rooms with names containing special characters not working [1st8]
+* #468 Fix [object Object] being sometimes shown as status [1st8]
 
 
 0.9.5 (2015-08-24)
 0.9.5 (2015-08-24)
 ------------------
 ------------------