mirror of
https://github.com/Rapptz/discord.py.git
synced 2025-07-01 07:40:07 +00:00
Fix Thread.applied_tags for media channels
This commit is contained in:
parent
7fe1102841
commit
e9f807e5ec
@ -272,12 +272,12 @@ class Thread(Messageable, Hashable):
|
||||
.. versionadded:: 2.1
|
||||
"""
|
||||
tags = []
|
||||
if self.parent is None or self.parent.type != ChannelType.forum:
|
||||
if self.parent is None or self.parent.type not in (ChannelType.forum, ChannelType.media):
|
||||
return tags
|
||||
|
||||
parent = self.parent
|
||||
for tag_id in self._applied_tags:
|
||||
tag = parent.get_tag(tag_id)
|
||||
tag = parent.get_tag(tag_id) # type: ignore # parent here will be ForumChannel instance
|
||||
if tag is not None:
|
||||
tags.append(tag)
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user