瀏覽代碼

muc: wait for `restoreSession`

JC Brand 5 年之前
父節點
當前提交
4aa6b728cf
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      src/headless/converse-muc.js

+ 1 - 1
src/headless/converse-muc.js

@@ -384,7 +384,7 @@ converse.plugins.add('converse-muc', {
                 this.setVCard();
                 this.set('box_id', `box-${btoa(this.get('jid'))}`);
 
-                this.restoreSession();
+                await this.restoreSession();
                 this.initFeatures(); // sendChatState depends on this.features
                 this.on('change:chat_state', this.sendChatState, this);
                 this.session.on('change:connection_status', this.onConnectionStatusChanged, this);