From 7f76a31a265587d95c470575cb5d56984e037e52 Mon Sep 17 00:00:00 2001 From: Rapptz Date: Tue, 14 Oct 2025 17:20:32 -0400 Subject: [PATCH] Use webp as the default emoji URL format Fix #10331 --- discord/emoji.py | 2 +- discord/partial_emoji.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/discord/emoji.py b/discord/emoji.py index 74f344acc..de6b47b69 100644 --- a/discord/emoji.py +++ b/discord/emoji.py @@ -165,7 +165,7 @@ class Emoji(_EmojiTag, AssetMixin): @property def url(self) -> str: """:class:`str`: Returns the URL of the emoji.""" - fmt = 'gif' if self.animated else 'png' + fmt = 'webp' if self.animated else 'png' return f'{Asset.BASE}/emojis/{self.id}.{fmt}' @property diff --git a/discord/partial_emoji.py b/discord/partial_emoji.py index 502202330..bbfbc099d 100644 --- a/discord/partial_emoji.py +++ b/discord/partial_emoji.py @@ -245,7 +245,7 @@ class PartialEmoji(_EmojiTag, AssetMixin): if self.is_unicode_emoji(): return '' - fmt = 'gif' if self.animated else 'png' + fmt = 'webp' if self.animated else 'png' return f'{Asset.BASE}/emojis/{self.id}.{fmt}' async def read(self) -> bytes: