diff --git a/discord/interactions.py b/discord/interactions.py index 85a58dfd5b..24c8e66528 100644 --- a/discord/interactions.py +++ b/discord/interactions.py @@ -925,7 +925,6 @@ async def send_message( if voice_message: payload["flags"] = payload.setdefault("flags", 0) + 8192 - if view is not None: payload["components"] = view.to_components() diff --git a/discord/webhook/async_.py b/discord/webhook/async_.py index b6be72cc8d..6e7a10592c 100644 --- a/discord/webhook/async_.py +++ b/discord/webhook/async_.py @@ -515,7 +515,7 @@ def create_interaction_response( "duration_secs": file.duration_secs, "waveform": file.waveform, # TODO: Fix content_type - #"content_type": "audio/mp3", + # "content_type": "audio/mp3", } ) form.append( @@ -524,8 +524,8 @@ def create_interaction_response( "value": file.fp, "filename": file.filename, # TODO: Fix content_type - #"content_type": "application/octet-stream", - #"content_type": "audio/mp3", + # "content_type": "application/octet-stream", + # "content_type": "audio/mp3", } ) payload["flags"] = 1 << 13 @@ -666,7 +666,9 @@ def handle_message_parameters( if username: payload["username"] = username - flags = MessageFlags(suppress_embeds=suppress, ephemeral=ephemeral, is_voice_message=voice_message) + flags = MessageFlags( + suppress_embeds=suppress, ephemeral=ephemeral, is_voice_message=voice_message + ) payload["flags"] = flags.value if applied_tags is not MISSING: @@ -1804,7 +1806,7 @@ async def send( applied_tags=applied_tags, allowed_mentions=allowed_mentions, previous_allowed_mentions=previous_mentions, - voice_message=voice_message + voice_message=voice_message, ) adapter = async_context.get() thread_id: int | None = None