diff --git a/src/backend/matrix_client.py b/src/backend/matrix_client.py index b499d905..c036bccb 100644 --- a/src/backend/matrix_client.py +++ b/src/backend/matrix_client.py @@ -522,8 +522,10 @@ class MatrixClient(nio.AsyncClient): mentions = mentions, ) - presence = self.models["accounts"][self.user_id].presence - while presence == Presence.State.offline: + while ( + self.models["accounts"][self.user_id].presence == + Presence.State.offline + ): await asyncio.sleep(0.2) await self._send_message(room_id, content, tx_id)