Skip to content

Commit

Permalink
types(InteractionWebhook): add client
Browse files Browse the repository at this point in the history
  • Loading branch information
Jiralite committed Nov 24, 2023
1 parent d0aa8d2 commit 021cd33
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions packages/discord.js/typings/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1921,6 +1921,7 @@ export class InteractionCollector<Interaction extends CollectedInteraction> exte

export class InteractionWebhook extends PartialWebhookMixin() {
public constructor(client: Client<true>, id: Snowflake, token: string);
public readonly client: Client;
public token: string;
public send(options: string | MessagePayload | InteractionReplyOptions): Promise<Message>;
public editMessage(
Expand Down
1 change: 1 addition & 0 deletions packages/discord.js/typings/index.test-d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2279,6 +2279,7 @@ expectType<Promise<APIMessage>>(webhookClient.send('content'));
expectType<Promise<APIMessage>>(webhookClient.editMessage(snowflake, 'content'));
expectType<Promise<APIMessage>>(webhookClient.fetchMessage(snowflake));

expectType<Client>(interactionWebhook.client);
expectType<Promise<Message>>(interactionWebhook.send('content'));
expectType<Promise<Message>>(interactionWebhook.editMessage(snowflake, 'content'));
expectType<Promise<Message>>(interactionWebhook.fetchMessage(snowflake));
Expand Down

0 comments on commit 021cd33

Please sign in to comment.