aboutsummaryrefslogtreecommitdiff
path: root/discord/enums.py
diff options
context:
space:
mode:
authorRapptz <[email protected]>2017-06-30 18:49:49 -0400
committerRapptz <[email protected]>2017-06-30 18:49:49 -0400
commit25a1d8c3004d061946533fffb901b225c38fdd66 (patch)
tree0fc03d21a1bf3f94e660b65fc530396604be06e1 /discord/enums.py
parentTypo in docstring for TextChannel.delete_messages (diff)
downloaddiscord.py-25a1d8c3004d061946533fffb901b225c38fdd66.tar.xz
discord.py-25a1d8c3004d061946533fffb901b225c38fdd66.zip
Add support for user flags in Profile.
Diffstat (limited to 'discord/enums.py')
-rw-r--r--discord/enums.py7
1 files changed, 6 insertions, 1 deletions
diff --git a/discord/enums.py b/discord/enums.py
index 51ceba8e..a2279b67 100644
--- a/discord/enums.py
+++ b/discord/enums.py
@@ -28,7 +28,7 @@ from enum import Enum
__all__ = ['ChannelType', 'MessageType', 'VoiceRegion', 'VerificationLevel',
'ContentFilter', 'Status', 'DefaultAvatar', 'RelationshipType',
- 'AuditLogAction', 'AuditLogActionCategory', ]
+ 'AuditLogAction', 'AuditLogActionCategory', 'UserFlags', ]
class ChannelType(Enum):
text = 0
@@ -204,6 +204,11 @@ class AuditLogAction(Enum):
elif v < 80:
return 'message'
+class UserFlags(Enum):
+ staff = 1
+ partner = 2
+ hypesquad = 4
+
def try_enum(cls, val):
"""A function that tries to turn the value into enum ``cls``.