muctab: fix closing a tab not in bookmarks

………
This commit is contained in:
mathieui 2021-01-24 12:41:09 +01:00
parent 5cfb0cbf43
commit 98bd4c241e

View file

@ -1525,10 +1525,9 @@ class MucTab(ChatTab):
"""
self.leave_room(msg)
if config.get('synchronise_open_rooms'):
if self.jid not in self.core.bookmarks:
return
self.core.bookmarks[self.jid].autojoin = False
self.core.bookmarks.save(self.core.xmpp)
if self.jid in self.core.bookmarks:
self.core.bookmarks[self.jid].autojoin = False
self.core.bookmarks.save(self.core.xmpp)
self.core.close_tab(self)
def on_close(self) -> None: