diff --git a/mautrix_telegram/portal/base.py b/mautrix_telegram/portal/base.py index 52a98edb..56c18313 100644 --- a/mautrix_telegram/portal/base.py +++ b/mautrix_telegram/portal/base.py @@ -147,8 +147,8 @@ class BasePortal(ABC): @property def has_bot(self) -> bool: - return ((bool(self.bot) and self.bot.is_in_chat(self.tgid)) - or (self.peer_type == "user" and self.tg_receiver == self.bot.tgid)) + return (bool(self.bot) and (self.bot.is_in_chat(self.tgid) + or (self.peer_type == "user" and self.tg_receiver == self.bot.tgid))) @property def main_intent(self) -> IntentAPI: