Rename Reaction.custom_emoji to Reaction.is_custom_emoji
This legacy attribute was apparently never changed to be consistent with the rest of the library
This commit is contained in:
parent
04788d0a06
commit
9181bf046b
@ -73,8 +73,7 @@ class Reaction:
|
|||||||
self.count = data.get('count', 1)
|
self.count = data.get('count', 1)
|
||||||
self.me = data.get('me')
|
self.me = data.get('me')
|
||||||
|
|
||||||
@property
|
def is_custom_emoji(self):
|
||||||
def custom_emoji(self):
|
|
||||||
""":class:`bool`: If this is a custom emoji."""
|
""":class:`bool`: If this is a custom emoji."""
|
||||||
return not isinstance(self.emoji, str)
|
return not isinstance(self.emoji, str)
|
||||||
|
|
||||||
@ -190,7 +189,7 @@ class Reaction:
|
|||||||
if the member has left the guild.
|
if the member has left the guild.
|
||||||
"""
|
"""
|
||||||
|
|
||||||
if self.custom_emoji:
|
if not isinstance(self.emoji, str):
|
||||||
emoji = f'{self.emoji.name}:{self.emoji.id}'
|
emoji = f'{self.emoji.name}:{self.emoji.id}'
|
||||||
else:
|
else:
|
||||||
emoji = self.emoji
|
emoji = self.emoji
|
||||||
|
Loading…
x
Reference in New Issue
Block a user