mirror of
https://github.com/tiramisulabs/seyfert.git
synced 2025-07-02 04:56:07 +00:00
fix: destructuring modal
This commit is contained in:
parent
e63d91f2b2
commit
9f8bec917b
@ -5,7 +5,9 @@ import { BaseShorter } from './base';
|
||||
export class InteractionShorter extends BaseShorter {
|
||||
async reply(id: string, token: string, body: ReplyInteractionBody) {
|
||||
//@ts-expect-error
|
||||
const { files, ...data } = body.data ?? {};
|
||||
const { files, ...rest } = body.data ?? {};
|
||||
//@ts-expect-error
|
||||
const data = body.data instanceof Modal ? body.data : rest;
|
||||
return this.client.proxy
|
||||
.interactions(id)(token)
|
||||
.callback.post({
|
||||
|
Loading…
x
Reference in New Issue
Block a user