Skip to content

Commit 2e4ace6

Browse files
committed
Fix: NopeView crashing on confirmation
1 parent eb5a881 commit 2e4ace6

File tree

1 file changed

+8
-6
lines changed

1 file changed

+8
-6
lines changed

eggsplode/ui/nope.py

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -166,9 +166,11 @@ async def ok_callback(self, interaction: discord.Interaction):
166166
async def finish_confirmation(self, interaction: discord.Interaction):
167167
self.game.last_interaction = interaction
168168
self.ignore_interactions()
169-
self.disable_all_items()
170-
self.remove_item(self.action_row)
171-
self.remove_item(self.timer_display)
172-
await interaction.edit(view=self)
173-
if self.ok_callback_action:
174-
await self.ok_callback_action(interaction)
169+
try:
170+
self.remove_item(self.action_row)
171+
self.remove_item(self.timer_display)
172+
self.disable_all_items()
173+
await interaction.edit(view=self)
174+
finally:
175+
if self.ok_callback_action:
176+
await self.ok_callback_action(interaction)

0 commit comments

Comments
 (0)