Skip to content

Commit 76eb126

Browse files
authored
Add 'mention' property in PartialWebhookChannel
1 parent 52967ec commit 76eb126

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

discord/webhook/async_.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -660,6 +660,11 @@ def __init__(self, *, data: PartialChannelPayload) -> None:
660660
def __repr__(self) -> str:
661661
return f'<PartialWebhookChannel name={self.name!r} id={self.id}>'
662662

663+
@property
664+
def mention(self) -> str:
665+
""":class:`str`: The string that allows you to mention the channel that the webhook is following."""
666+
return f'<#{self.id}>'
667+
663668

664669
class PartialWebhookGuild(Hashable):
665670
"""Represents a partial guild for webhooks.

0 commit comments

Comments
 (0)