Skip to content

Commit

Permalink
Fix false positives in animated for PartialEmoji.from_str
Browse files Browse the repository at this point in the history
  • Loading branch information
AbstractUmbra authored Jun 21, 2023
1 parent 49e31e9 commit a7f2c67
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion discord/partial_emoji.py
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ class PartialEmoji(_EmojiTag, AssetMixin):

__slots__ = ('animated', 'name', 'id', '_state')

_CUSTOM_EMOJI_RE = re.compile(r'<?(?P<animated>a)?:?(?P<name>[A-Za-z0-9\_]+):(?P<id>[0-9]{13,20})>?')
_CUSTOM_EMOJI_RE = re.compile(r'<?(?:(?P<animated>a)?:)?(?P<name>[A-Za-z0-9\_]+):(?P<id>[0-9]{13,20})>?')

if TYPE_CHECKING:
id: Optional[int]
Expand Down

0 comments on commit a7f2c67

Please sign in to comment.