Browse Source

fix: Skip sending multiple times disco-info to jicofo.

dev1
damencho 4 years ago
parent
commit
8bb653f1d6
1 changed files with 9 additions and 0 deletions
  1. 9
    0
      modules/xmpp/ChatRoom.js

+ 9
- 0
modules/xmpp/ChatRoom.js View File

641
                 // participant joins during that period of time the first
641
                 // participant joins during that period of time the first
642
                 // presence from the focus won't contain
642
                 // presence from the focus won't contain
643
                 // <item jid="focus..." />.
643
                 // <item jid="focus..." />.
644
+                // By default we are disabling the waiting for form submission in order to use the room
645
+                // and we had enabled by default that jids are public in the room ,
646
+                // so this case should not happen, if public jid is turned off we will receive the jid
647
+                // when we become moderator in the room
644
                 memberOfThis.isFocus = true;
648
                 memberOfThis.isFocus = true;
645
                 this._initFocus(from, jid);
649
                 this._initFocus(from, jid);
646
             }
650
             }
758
      * @param mucJid the jid of the focus in the muc
762
      * @param mucJid the jid of the focus in the muc
759
      */
763
      */
760
     _initFocus(from, mucJid) {
764
     _initFocus(from, mucJid) {
765
+        // skip if we have queried jicofo already, it will not change
766
+        if (this.focusFeatures) {
767
+            return;
768
+        }
769
+
761
         this.focusMucJid = from;
770
         this.focusMucJid = from;
762
 
771
 
763
         logger.info(`Ignore focus: ${from}, real JID: ${mucJid}`);
772
         logger.info(`Ignore focus: ${from}, real JID: ${mucJid}`);

Loading…
Cancel
Save