fix(core): Support attachment editing on interactions (#9356)

fix(core): support attachment editing on interactions

Co-authored-by: Vlad Frangu <kingdgrizzle@gmail.com>
Co-authored-by: kodiakhq[bot] <49736102+kodiakhq[bot]@users.noreply.github.com>
This commit is contained in:
Jiralite
2023-04-10 21:35:54 +01:00
committed by GitHub
parent 23e0ac56f4
commit 676307ff5c

View File

@@ -238,7 +238,11 @@ export class WebhooksAPI {
id: Snowflake,
token: string,
messageId: Snowflake,
{ thread_id, ...body }: RESTPatchAPIWebhookWithTokenMessageJSONBody & { thread_id?: string },
{
thread_id,
files,
...body
}: RESTPatchAPIWebhookWithTokenMessageJSONBody & { files?: RawFile[]; thread_id?: string },
{ signal }: Pick<RequestData, 'signal'> = {},
) {
return this.rest.patch(Routes.webhookMessage(id, token, messageId), {
@@ -246,6 +250,7 @@ export class WebhooksAPI {
auth: false,
body,
signal,
files,
}) as Promise<RESTPatchAPIWebhookWithTokenMessageResult>;
}