Compare commits
4 Commits
0c0040d3d2
...
master
| Author | SHA1 | Date | |
|---|---|---|---|
| 2f4778d0b8 | |||
| d7ef852ebb | |||
| 0326220880 | |||
| 8791c37473 |
@@ -76,7 +76,6 @@ class TrackerComponent(cmds.Component):
|
|||||||
eventsub.StreamOnlineSubscription,
|
eventsub.StreamOnlineSubscription,
|
||||||
eventsub.StreamOfflineSubscription,
|
eventsub.StreamOfflineSubscription,
|
||||||
eventsub.ChannelUpdateSubscription,
|
eventsub.ChannelUpdateSubscription,
|
||||||
eventsub.ChannelNotificationSubscription,
|
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
|
|
||||||
@@ -106,6 +105,10 @@ class TrackerComponent(cmds.Component):
|
|||||||
eventsub.ChannelRaidSubscription(
|
eventsub.ChannelRaidSubscription(
|
||||||
from_broadcaster_user_id=channel.userid
|
from_broadcaster_user_id=channel.userid
|
||||||
),
|
),
|
||||||
|
eventsub.ChatNotificationSubscription(
|
||||||
|
broadcaster_user_id=channel.userid,
|
||||||
|
user_id=self.bot.bot_id,
|
||||||
|
),
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
|
|
||||||
@@ -464,7 +467,7 @@ class TrackerComponent(cmds.Component):
|
|||||||
)
|
)
|
||||||
detail_row = await self.data.notice_sub_events.insert(
|
detail_row = await self.data.notice_sub_events.insert(
|
||||||
event_id=event_row["event_id"],
|
event_id=event_row["event_id"],
|
||||||
tier=int(payload.tier),
|
tier=int(payload.sub.tier),
|
||||||
is_prime=payload.sub.prime,
|
is_prime=payload.sub.prime,
|
||||||
duration_months=payload.sub.months,
|
duration_months=payload.sub.months,
|
||||||
)
|
)
|
||||||
@@ -482,7 +485,6 @@ class TrackerComponent(cmds.Component):
|
|||||||
)
|
)
|
||||||
detail_row = await self.data.notice_resub_events.insert(
|
detail_row = await self.data.notice_resub_events.insert(
|
||||||
event_id=event_row["event_id"],
|
event_id=event_row["event_id"],
|
||||||
message_id=payload.id,
|
|
||||||
tier=payload.resub.tier,
|
tier=payload.resub.tier,
|
||||||
is_prime=payload.resub.prime,
|
is_prime=payload.resub.prime,
|
||||||
is_gift=payload.resub.gift,
|
is_gift=payload.resub.gift,
|
||||||
|
|||||||
+2
-1
@@ -1,4 +1,5 @@
|
|||||||
import twitchio
|
import twitchio
|
||||||
|
from twitchio.types_.eventsub import *
|
||||||
|
|
||||||
|
|
||||||
class ChatNotificationWithPayload(twitchio.ChatNotification):
|
class ChatNotificationWithPayload(twitchio.ChatNotification):
|
||||||
@@ -10,6 +11,6 @@ class ChatNotificationWithPayload(twitchio.ChatNotification):
|
|||||||
|
|
||||||
__slots__ = ("_raw",)
|
__slots__ = ("_raw",)
|
||||||
|
|
||||||
def __init__(self, payload: twitchio.ChannelChatNotificationEvent, *args, **kwargs):
|
def __init__(self, payload: ChannelChatNotificationEvent, *args, **kwargs):
|
||||||
super().__init__(payload, *args, **kwargs)
|
super().__init__(payload, *args, **kwargs)
|
||||||
self._raw = payload
|
self._raw = payload
|
||||||
|
|||||||
Reference in New Issue
Block a user