diff --git a/src/modules/stream_notifications/messages_proc.py b/src/modules/stream_notifications/messages_proc.py index e2b8f56..54a7b06 100644 --- a/src/modules/stream_notifications/messages_proc.py +++ b/src/modules/stream_notifications/messages_proc.py @@ -315,7 +315,7 @@ class MessagesProc: # ) @classmethod - async def on_message(cls, event: MessageEvent): + async def on_message(cls, received_as: str, event: MessageEvent): if event.chatter_user_name in cls.FULL_IGNORED_USER_LOGINS: return @@ -323,7 +323,7 @@ class MessagesProc: await cls._update_history(event) - twitch = await authorize(event.broadcaster_user_login) + twitch = await authorize(received_as) await cls._goida(twitch, event) await cls._lasqexx(twitch, event) diff --git a/src/modules/stream_notifications/tasks.py b/src/modules/stream_notifications/tasks.py index 13744bd..e8a83a3 100644 --- a/src/modules/stream_notifications/tasks.py +++ b/src/modules/stream_notifications/tasks.py @@ -81,8 +81,11 @@ async def check_streams_states(): "stream_notifications.on_message", retry_on_error=True ) -async def on_message(event: MessageEvent): - await MessagesProc.on_message(event) +async def on_message( + received_as: str, + event: MessageEvent +): + await MessagesProc.on_message(received_as, event) @broker.task( diff --git a/src/modules/stream_notifications/twitch/webhook.py b/src/modules/stream_notifications/twitch/webhook.py index 4411793..9aa2110 100644 --- a/src/modules/stream_notifications/twitch/webhook.py +++ b/src/modules/stream_notifications/twitch/webhook.py @@ -54,6 +54,7 @@ class TwitchService: async def on_message(self, event: ChannelChatMessageEvent): await on_message.kiq( + self.streamer.twitch.name, MessageEvent.from_twitch_event(event) )