Bug 1180435 - Avoid duplicating topic system message when joining a room. r=aleth a=clokep CLOSED TREE
authorAbdelrhman Ahmed <a.ahmed1026@gmail.com>
Wed, 15 Jul 2015 04:21:00 +0200
changeset 18123 3487a322b28d8ceec33d4f1b9944153924b13359
parent 18122 40330e8b3ee071a9ac9d8b3335e5fdc838626ff4
child 18124 dd68254da2587021c7e1f8acb34e39d5304d36e0
push id11136
push userclokep@gmail.com
push dateThu, 23 Jul 2015 23:11:01 +0000
treeherdercomm-central@3487a322b28d [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersaleth, clokep
bugs1180435
Bug 1180435 - Avoid duplicating topic system message when joining a room. r=aleth a=clokep CLOSED TREE
chat/protocols/xmpp/xmpp.jsm
--- a/chat/protocols/xmpp/xmpp.jsm
+++ b/chat/protocols/xmpp/xmpp.jsm
@@ -1385,16 +1385,17 @@ const XMPPAccountPrototype = {
       // <subject/> but no <body/> element shall be considered a subject change
       // for MUC, but we ignore that to be compatible with ejabberd versions
       // before 15.06.
       let muc = this._mucs.get(norm);
       let nick = this._parseJID(from).resource;
       // TODO There can be multiple subject elements with different xml:lang
       // attributes.
       muc.setTopic(subject.innerText, nick);
+      return;
     }
 
     if (body) {
       let date;
       let delay = aStanza.getElement(["delay"]);
       if (delay && delay.uri == Stanza.NS.delay) {
         if (delay.attributes["stamp"])
           date = new Date(delay.attributes["stamp"]);