fix: add step_type to default approve/reject/timeout callbacks (not just multi-choice)

This commit is contained in:
2026-03-10 15:29:55 +09:00
parent 26c19fb6be
commit 0470c03ab3
5 changed files with 9 additions and 3 deletions

3
bot.py
View File

@@ -110,6 +110,7 @@ class ApprovalView(discord.ui.View):
self.responded = True
self.bridge.write_response(UserResponse(
request_id=self.request.request_id, approved=True,
step_type=getattr(self.request, 'step_type', ''),
))
embed = interaction.message.embeds[0] if interaction.message.embeds else None
if embed:
@@ -128,6 +129,7 @@ class ApprovalView(discord.ui.View):
self.responded = True
self.bridge.write_response(UserResponse(
request_id=self.request.request_id, approved=False,
step_type=getattr(self.request, 'step_type', ''),
))
embed = interaction.message.embeds[0] if interaction.message.embeds else None
if embed:
@@ -139,6 +141,7 @@ class ApprovalView(discord.ui.View):
if not self.responded:
self.bridge.write_response(UserResponse(
request_id=self.request.request_id, approved=False,
step_type=getattr(self.request, 'step_type', ''),
))