diff --git a/mautrix_facebook/user.py b/mautrix_facebook/user.py index 9d2818dc8debb121c2fd519c01e7bc325422f4eb..794aa6877ad0155fb7a3d348fc7f6abdb598ae25 100644 --- a/mautrix_facebook/user.py +++ b/mautrix_facebook/user.py @@ -244,6 +244,7 @@ class User(BaseUser): self.log.info("Loaded session successfully") self.session = session self.client = fbchat.Client(session=self.session) + METRIC_LOGGED_IN.labels('fbid', self.fbid).state('true') self._is_logged_in = True self.is_connected = None self.stop_listening() @@ -623,7 +624,6 @@ class User(BaseUser): self.save() self.stop_listening() self.start_listen() - METRIC_LOGGED_IN.labels('fbid', self.fbid).state('true') asyncio.ensure_future(self.post_login(), loop=self.loop) @METRIC_MESSAGE.time()