Fixes #1783
This commit is contained in:
parent
5809c97828
commit
7fc3151e56
@ -90,7 +90,7 @@ converse.plugins.add('converse-bosh', {
|
||||
|
||||
_converse.restoreBOSHSession = async function () {
|
||||
const jid = (await initBOSHSession()).get('jid');
|
||||
if (jid) {
|
||||
if (jid && (_converse.connection._proto instanceof Strophe.Bosh)) {
|
||||
try {
|
||||
_converse.connection.restore(jid, _converse.onConnectStatusChanged);
|
||||
return true;
|
||||
|
@ -1397,7 +1397,8 @@ _converse.api = {
|
||||
}
|
||||
|
||||
// See whether there is a BOSH session to re-attach to
|
||||
if (_.invoke(_converse.pluggable.plugins['converse-bosh'], 'enabled')) {
|
||||
const bosh_plugin = _converse.pluggable.plugins['converse-bosh'];
|
||||
if (bosh_plugin && bosh_plugin.enabled()) {
|
||||
if (await _converse.restoreBOSHSession()) {
|
||||
return;
|
||||
} else if (_converse.authentication === _converse.PREBIND && (!automatic || _converse.auto_login)) {
|
||||
|
@ -27,6 +27,7 @@
|
||||
muc_respect_autojoin: true,
|
||||
view_mode: 'fullscreen',
|
||||
websocket_url: 'ws://chat.example.org:5380/xmpp-websocket',
|
||||
// bosh_service_url: 'http://chat.example.org:5280/http-bind',
|
||||
muc_show_logs_before_join: true,
|
||||
whitelisted_plugins: ['converse-debug'],
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user