Add Role.mention property
This commit is contained in:
1 parent
07adb1d5e9
commit
abb955fdaa
1 file changed
+5
@@ -96,3 +96,8 @@ class Role(Hashable):
|
||||
def created_at(self):
|
||||
"""Returns the role's creation time in UTC."""
|
||||
return snowflake_time(self.id)
|
||||
|
||||
@property
|
||||
def mention(self):
|
||||
"""Returns a string that allows you to mention a role."""
|
||||
return '<@&{}>'.format(self.id)
|
||||
Reference in new issue
Block a user