mirror of
https://github.com/discordeno/discordeno.git
synced 2026-06-02 00:40:07 +00:00
fix(helpers): edit interaction responses & webhook messages does not update files (#2483)
Closes: #2482 Co-authored-by: Skillz4Killz <23035000+Skillz4Killz@users.noreply.github.com>
This commit is contained in:
@@ -38,6 +38,7 @@ export async function editFollowupMessage(
|
||||
type: InteractionResponseTypes.UpdateMessage,
|
||||
data: options,
|
||||
}).data,
|
||||
file: options.file,
|
||||
},
|
||||
);
|
||||
|
||||
|
||||
@@ -29,10 +29,13 @@ export async function editOriginalInteractionResponse(
|
||||
bot.rest,
|
||||
"PATCH",
|
||||
bot.constants.routes.INTERACTION_ORIGINAL_ID_TOKEN(bot.applicationId, token),
|
||||
bot.transformers.reverse.interactionResponse(bot, {
|
||||
type: InteractionResponseTypes.UpdateMessage,
|
||||
data: options,
|
||||
}).data,
|
||||
{
|
||||
...bot.transformers.reverse.interactionResponse(bot, {
|
||||
type: InteractionResponseTypes.UpdateMessage,
|
||||
data: options,
|
||||
}).data,
|
||||
file: options.file,
|
||||
},
|
||||
);
|
||||
|
||||
return bot.transformers.message(bot, result);
|
||||
|
||||
@@ -27,10 +27,13 @@ export async function editOriginalWebhookMessage(
|
||||
bot.rest,
|
||||
"PATCH",
|
||||
bot.constants.routes.WEBHOOK_MESSAGE_ORIGINAL(webhookId, token, options),
|
||||
bot.transformers.reverse.interactionResponse(bot, {
|
||||
type: InteractionResponseTypes.UpdateMessage,
|
||||
data: options,
|
||||
}).data,
|
||||
{
|
||||
...bot.transformers.reverse.interactionResponse(bot, {
|
||||
type: InteractionResponseTypes.UpdateMessage,
|
||||
data: options,
|
||||
}).data,
|
||||
file: options.file,
|
||||
},
|
||||
);
|
||||
|
||||
return bot.transformers.message(bot, result);
|
||||
|
||||
@@ -30,10 +30,13 @@ export async function editWebhookMessage(
|
||||
bot.rest,
|
||||
"PATCH",
|
||||
bot.constants.routes.WEBHOOK_MESSAGE(webhookId, token, messageId, options),
|
||||
bot.transformers.reverse.interactionResponse(bot, {
|
||||
type: InteractionResponseTypes.UpdateMessage,
|
||||
data: options,
|
||||
}).data,
|
||||
{
|
||||
...bot.transformers.reverse.interactionResponse(bot, {
|
||||
type: InteractionResponseTypes.UpdateMessage,
|
||||
data: options,
|
||||
}).data,
|
||||
file: options.file,
|
||||
},
|
||||
);
|
||||
|
||||
return bot.transformers.message(bot, result);
|
||||
|
||||
Reference in New Issue
Block a user