Closed anon97945 closed 1 year ago
🚫 [ERROR] hikka.modules.inline_spotify: BRUH
Traceback (most recent call last):
File "https://mods.hikariatama.ru/inline_spotify.py", line 157, in inline_iter
any(uid == i.unit_uid for i in self._active_forms)
File "https://mods.hikariatama.ru/inline_spotify.py", line 157, in <genexpr>
any(uid == i.unit_uid for i in self._active_forms)
AttributeError: 'InlineMessage' object has no attribute 'unit_uid'
activists | it doesn't count self in groups.
Not a bug. It's intended behavior to not count admins. I'll make a config value to add ability to change this
- [x] silent_tags.py | properly handle messages from channels
from telethon.tl.types import Message, Channel
https://github.com/hikariatama/ftg/blob/master/silent_tags.py#L22
if (
(
self.config["whitelist"]
and message.sender_id not in (self.config["silent_users"] or [])
or not self.config["whitelist"]
and message.sender_id in (self.config["silent_users"] or [])
)
or self.config["silent_blocked"]
and message.sender.id in self._blocked
or (
self.config["whitelist"]
and utils.get_chat_id(message)
not in (self.config["silent_chats"] or [])
or not self.config["whitelist"]
and utils.get_chat_id(message) in (self.config["silent_chats"] or [])
)
):
return
if not (isinstance(user, Channel)):
if self.config["silent_bots"] and message.sender.bot:
return
https://github.com/hikariatama/ftg/blob/master/silent_tags.py#L270-L289
should be :
if self.config["ignore_blocked"] or self.config["silent_blocked"]:
instead of:
if self.config["ignore_blocked"]
https://github.com/hikariatama/ftg/blob/af63c0c9c2459adf019465a9e5fa2c86747cbf08/silent_tags.py#L167