Commit ffa04cc7 authored by Philipp Hörist's avatar Philipp Hörist
Browse files

MUC: Reset state after connect without resumption

Fixes #10200
parent 4a082480
......@@ -329,6 +329,7 @@ class Client(ConnectionHandlers):
def _on_connected(self, _client, _signal_name):
self._set_state(ClientState.CONNECTED)
self.get_module('MUC').get_manager().reset_state()
self.get_module('Discovery').discover_server_info()
self.get_module('Discovery').discover_account_info()
self.get_module('Discovery').discover_server_items()
......
......@@ -818,6 +818,10 @@ class MUCManager:
def get_mucs_with_state(self, states):
return [muc for muc in self._mucs.values() if muc.state in states]
def reset_state(self):
for muc in self._mucs.values():
self.set_state(muc.jid, MUCJoinedState.NOT_JOINED)
def __contains__(self, room_jid):
return room_jid in self._mucs
......
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