Commit 0002c0bd authored by JC Brand's avatar JC Brand

`converse._tearDown` shouldn't be called from converse-controlbox.js

parent 7398d414
......@@ -51,7 +51,6 @@
onDisconnected: function () {
var result = this._super.onDisconnected.apply(this, arguments);
if (result === 'disconnected') {
converse._tearDown();
var view = converse.chatboxviews.get('controlbox');
view.model.set({connected:false});
view.$('#controlbox-tabs').empty();
......
......@@ -449,6 +449,7 @@
converse.reconnect(condition);
return 'reconnecting';
} else {
converse._tearDown();
converse.emit('disconnected');
return 'disconnected';
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment