Skip to content

Commit

Permalink
Fix interaction failed message
Browse files Browse the repository at this point in the history
  • Loading branch information
SeoulSKY committed Dec 1, 2024
1 parent ff11ff2 commit 86e7912
Showing 1 changed file with 2 additions and 8 deletions.
10 changes: 2 additions & 8 deletions src/utils/ui.py
Original file line number Diff line number Diff line change
Expand Up @@ -161,14 +161,8 @@ async def callback(select_interaction: Interaction, select: Select) -> None:
option.default = option.value in self._selected

await interaction.edit_original_response(view=self)

try:
await select_interaction.response.send_message()
except HTTPException as ex:
if ex.code == ErrorCode.MESSAGE_EMPTY:
return

raise
# End the interaction without replying
await select_interaction.response.defer(ephemeral=True)

for i in range(0, len(options), Limit.SELECT_MAX.value):
partial_options = options[i : i + Limit.SELECT_MAX.value]
Expand Down

0 comments on commit 86e7912

Please sign in to comment.