mirror of
https://github.com/Rapptz/discord.py.git
synced 2025-04-22 08:44:10 +00:00
Add CHANNEL_FOLLOW_ADD Message Type
Add documentation for MessageType.channel_follow_add Add versionchanged to new MessageType attr Add system_content for new MessageType
This commit is contained in:
parent
125a5676b8
commit
da4bb0610c
@ -171,6 +171,7 @@ class MessageType(Enum):
|
||||
premium_guild_tier_1 = 9
|
||||
premium_guild_tier_2 = 10
|
||||
premium_guild_tier_3 = 11
|
||||
channel_follow_add = 12
|
||||
|
||||
class VoiceRegion(Enum):
|
||||
us_west = 'us-west'
|
||||
|
@ -669,6 +669,9 @@ class Message:
|
||||
if self.type is MessageType.premium_guild_tier_3:
|
||||
return '{0.author.name} just boosted the server! {0.guild} has achieved **Level 3!**'.format(self)
|
||||
|
||||
if self.type is MessageType.channel_follow_add:
|
||||
return '{0.author.name} has added {0.content} to this channel'.format(self)
|
||||
|
||||
async def delete(self, *, delay=None):
|
||||
"""|coro|
|
||||
|
||||
|
@ -760,6 +760,9 @@ of :class:`enum.Enum`.
|
||||
Specifies the type of :class:`Message`. This is used to denote if a message
|
||||
is to be interpreted as a system message or a regular message.
|
||||
|
||||
.. versionchanged:: 1.3.0
|
||||
The ``channel_follow_add`` attribute was added.
|
||||
|
||||
.. attribute:: default
|
||||
|
||||
The default message type. This is the same as regular messages.
|
||||
@ -803,6 +806,9 @@ of :class:`enum.Enum`.
|
||||
|
||||
The system message denoting that a member has "nitro boosted" a guild
|
||||
and it achieved level 3.
|
||||
.. attribute:: channel_follow_add
|
||||
|
||||
The system message denoting that an announcement channel has been followed.
|
||||
|
||||
.. class:: ActivityType
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user