From 5075741382e2c548b2a0f1a770a0d38828f0d1c2 Mon Sep 17 00:00:00 2001 From: reddyyateesh Date: Tue, 4 Mar 2025 23:05:18 +0530 Subject: [PATCH] Store raw values for AttachmentFlags in Embed media properties --- discord/embeds.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/discord/embeds.py b/discord/embeds.py index b35582b9f..9508147d5 100644 --- a/discord/embeds.py +++ b/discord/embeds.py @@ -414,7 +414,7 @@ class Embed: """ # Lying to the type checker for better developer UX. data = getattr(self, '_image', {}) - data['flags'] = AttachmentFlags._from_value(data.get('flags', 0)) + data['flags'] = data.get('flags', 0) return EmbedProxy(data) # type: ignore def set_image(self, *, url: Optional[Any]) -> Self: @@ -459,7 +459,7 @@ class Embed: """ # Lying to the type checker for better developer UX. data = getattr(self, '_thumbnail', {}) - data['flags'] = AttachmentFlags._from_value(data.get('flags', 0)) + data['flags'] = data.get('flags', 0) return EmbedProxy(data) # type: ignore def set_thumbnail(self, *, url: Optional[Any]) -> Self: @@ -504,7 +504,7 @@ class Embed: """ # Lying to the type checker for better developer UX. data = getattr(self, '_video', {}) - data['flags'] = AttachmentFlags._from_value(data.get('flags', 0)) + data['flags'] = data.get('flags', 0) return EmbedProxy(data) # type: ignore @property