Skip to content

Commit 307202c

Browse files
Dschogochillymosh
andauthored
set correct "type" of PubSubModerationActionChannelTerms (#332)
set correct "type" of PubSubModerationActionChannelTerms Co-authored-by: chillymosh <[email protected]>
1 parent f02154b commit 307202c

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

docs/changelog.rst

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,11 @@ Master
5353
- :func:`~twitchio.ext.eventsub.event_eventsub_notification_channel_goal_end`
5454

5555
- Bug fixes
56-
Correct typo in :class:`~twitchio.ext.eventsub.HypeTrainBeginProgressData` attribute :attr:`~twitchio.ext.eventsub.HypeTrainBeginProgressData.expires`
56+
Correct typo in :class:`~twitchio.ext.eventsub.HypeTrainBeginProgressData` attribute :attr:`~twitchio.ext.eventsub.HypeTrainBeginProgressData.expires`
57+
58+
- ext.pubsub
59+
- Bug fixes
60+
- "type" of :class:`~twitchio.ext.pubsub.PubSubModerationActionChannelTerms` now uses the correct type data
5761

5862

5963
2.4.0

twitchio/ext/pubsub/models.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -329,7 +329,7 @@ class PubSubModerationActionChannelTerms(PubSubMessage):
329329

330330
def __init__(self, client: Client, topic: str, data: dict):
331331
super().__init__(client, topic, data)
332-
self.type: str = data["message"]["type"]
332+
self.type: str = data["message"]["data"]["type"]
333333
self.channel_id = int(data["message"]["data"]["channel_id"])
334334
self.id: str = data["message"]["data"]["id"]
335335
self.text: str = data["message"]["data"]["text"]

0 commit comments

Comments
 (0)