aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRapptz <[email protected]>2021-07-03 11:02:32 -0400
committerRapptz <[email protected]>2021-07-03 11:02:32 -0400
commit3d0dd5bc1be91c393ba5844dbd884e98b6dfb97c (patch)
tree681d87a91b156c7ee293dd588bbd3295bb7dc52f
parentAdd support for fetching the original interaction response message (diff)
downloaddiscord.py-3d0dd5bc1be91c393ba5844dbd884e98b6dfb97c.tar.xz
discord.py-3d0dd5bc1be91c393ba5844dbd884e98b6dfb97c.zip
Change Message.__repr__ to show inherited type name
-rw-r--r--discord/message.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/discord/message.py b/discord/message.py
index 4ae3fe7c..4d80ec39 100644
--- a/discord/message.py
+++ b/discord/message.py
@@ -703,8 +703,9 @@ class Message(Hashable):
continue
def __repr__(self) -> str:
+ name = self.__class__.__name__
return (
- f'<Message id={self.id} channel={self.channel!r} type={self.type!r} author={self.author!r} flags={self.flags!r}>'
+ f'<{name} id={self.id} channel={self.channel!r} type={self.type!r} author={self.author!r} flags={self.flags!r}>'
)
def _try_patch(self, data, key, transform=None) -> None:
@@ -1224,7 +1225,6 @@ class Message(Hashable):
flags.suppress_embeds = suppress
payload['flags'] = flags.value
-
if allowed_mentions is MISSING:
if self._state.allowed_mentions is not None and self.author.id == self._state.self_id:
payload['allowed_mentions'] = self._state.allowed_mentions.to_dict()