Skip to content

Commit 859323a

Browse files
fix: prevent already responded error in image workaround
1 parent 61a6d67 commit 859323a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

interactions/models/internal/context.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -403,7 +403,7 @@ async def defer(self, *, ephemeral: bool = False) -> None:
403403
async def _send_http_request(
404404
self, message_payload: dict, files: typing.Iterable["UPLOADABLE_TYPE"] | None = None
405405
) -> dict:
406-
if const.has_client_feature("FOLLOWUP_INTERACTIONS_FOR_IMAGES") and not self.deferred:
406+
if const.has_client_feature("FOLLOWUP_INTERACTIONS_FOR_IMAGES") and not self.deferred and not self.responded:
407407
# experimental bypass for discords broken image proxy
408408
if embeds := message_payload.get("embeds", {}):
409409
if any(e.get("image") for e in embeds) or any(e.get("thumbnail") for e in embeds):

0 commit comments

Comments
 (0)