diff --git a/packages/discord.js/src/structures/CommandInteraction.js b/packages/discord.js/src/structures/CommandInteraction.js
index 0d435deeb446..d872c4d5956b 100644
--- a/packages/discord.js/src/structures/CommandInteraction.js
+++ b/packages/discord.js/src/structures/CommandInteraction.js
@@ -148,15 +148,15 @@ class CommandInteraction extends BaseInteraction {
/* eslint-disable no-empty-function */
deferReply() {}
reply() {}
- fetchReply() {}
- editReply() {}
- deleteReply() {}
+ fetchResponse() {}
+ editResponse() {}
+ deleteResponse() {}
followUp() {}
showModal() {}
sendPremiumRequired() {}
awaitModalSubmit() {}
}
-InteractionResponses.applyToClass(CommandInteraction, ['deferUpdate', 'update']);
+InteractionResponses.applyToClass(CommandInteraction, ['deferMessageUpdate', 'updateMessage']);
module.exports = CommandInteraction;
diff --git a/packages/discord.js/src/structures/MessageComponentInteraction.js b/packages/discord.js/src/structures/MessageComponentInteraction.js
index 2e6df11e5611..aa8e7badf0f5 100644
--- a/packages/discord.js/src/structures/MessageComponentInteraction.js
+++ b/packages/discord.js/src/structures/MessageComponentInteraction.js
@@ -92,12 +92,12 @@ class MessageComponentInteraction extends BaseInteraction {
/* eslint-disable no-empty-function */
deferReply() {}
reply() {}
- fetchReply() {}
- editReply() {}
- deleteReply() {}
+ fetchResponse() {}
+ editResponse() {}
+ deleteResponse() {}
followUp() {}
- deferUpdate() {}
- update() {}
+ deferMessageUpdate() {}
+ updateMessage() {}
showModal() {}
sendPremiumRequired() {}
awaitModalSubmit() {}
diff --git a/packages/discord.js/src/structures/MessagePayload.js b/packages/discord.js/src/structures/MessagePayload.js
index dad8ffedb026..ba358dd4250b 100644
--- a/packages/discord.js/src/structures/MessagePayload.js
+++ b/packages/discord.js/src/structures/MessagePayload.js
@@ -321,7 +321,7 @@ module.exports = MessagePayload;
/**
* A possible payload option.
* @typedef {MessageCreateOptions|MessageEditOptions|WebhookMessageCreateOptions|WebhookMessageEditOptions|
- * InteractionReplyOptions|InteractionUpdateOptions} MessagePayloadOption
+ * InteractionReplyOptions|InteractionUpdateMessageOptions} MessagePayloadOption
*/
/**
diff --git a/packages/discord.js/src/structures/ModalSubmitInteraction.js b/packages/discord.js/src/structures/ModalSubmitInteraction.js
index ba94190436da..73bff747f450 100644
--- a/packages/discord.js/src/structures/ModalSubmitInteraction.js
+++ b/packages/discord.js/src/structures/ModalSubmitInteraction.js
@@ -112,12 +112,12 @@ class ModalSubmitInteraction extends BaseInteraction {
/* eslint-disable no-empty-function */
deferReply() {}
reply() {}
- fetchReply() {}
- editReply() {}
- deleteReply() {}
+ fetchResponse() {}
+ editResponse() {}
+ deleteResponse() {}
followUp() {}
- deferUpdate() {}
- update() {}
+ deferMessageUpdate() {}
+ updateMessage() {}
sendPremiumRequired() {}
}
diff --git a/packages/discord.js/src/structures/interfaces/InteractionResponses.js b/packages/discord.js/src/structures/interfaces/InteractionResponses.js
index 9f711b517b49..386119dd09ff 100644
--- a/packages/discord.js/src/structures/interfaces/InteractionResponses.js
+++ b/packages/discord.js/src/structures/interfaces/InteractionResponses.js
@@ -25,13 +25,13 @@ class InteractionResponses {
* Options for deferring the reply to an {@link BaseInteraction}.
* @typedef {Object} InteractionDeferReplyOptions
* @property {boolean} [ephemeral] Whether the reply should be ephemeral
- * @property {boolean} [fetchReply] Whether to fetch the reply
+ * @property {boolean} [fetchResponse] Whether to fetch the reply
*/
/**
* Options for deferring and updating the reply to a {@link MessageComponentInteraction}.
- * @typedef {Object} InteractionDeferUpdateOptions
- * @property {boolean} [fetchReply] Whether to fetch the reply
+ * @typedef {Object} InteractionDeferMessageUpdateOptions
+ * @property {boolean} [fetchResponse] Whether to fetch the reply
*/
/**
@@ -39,7 +39,7 @@ class InteractionResponses {
* @typedef {BaseMessageOptions} InteractionReplyOptions
* @property {boolean} [tts=false] Whether the message should be spoken aloud
* @property {boolean} [ephemeral] Whether the reply should be ephemeral
- * @property {boolean} [fetchReply] Whether to fetch the reply
+ * @property {boolean} [fetchResponse] Whether to fetch the reply
* @property {MessageFlags} [flags] Which flags to set for the message.
* Only `MessageFlags.Ephemeral`, `MessageFlags.SuppressEmbeds`, and `MessageFlags.SuppressNotifications`
* can be set.
@@ -47,8 +47,8 @@ class InteractionResponses {
/**
* Options for updating the message received from a {@link MessageComponentInteraction}.
- * @typedef {MessageEditOptions} InteractionUpdateOptions
- * @property {boolean} [fetchReply] Whether to fetch the reply
+ * @typedef {MessageEditOptions} InteractionUpdateMessageOptions
+ * @property {boolean} [fetchResponse] Whether to fetch the reply
*/
/**
@@ -80,17 +80,17 @@ class InteractionResponses {
});
this.deferred = true;
- return options.fetchReply ? this.fetchReply() : new InteractionResponse(this);
+ return options.fetchResponse ? this.fetchResponse() : new InteractionResponse(this);
}
/**
* Creates a reply to this interaction.
- * Use the `fetchReply` option to get the bot's reply message.
+ * Use the `fetchResponse` option to get the bot's reply message.
* @param {string|MessagePayload|InteractionReplyOptions} options The options for the reply
* @returns {Promise}
* @example
* // Reply to the interaction and fetch the response
- * interaction.reply({ content: 'Pong!', fetchReply: true })
+ * interaction.reply({ content: 'Pong!', fetchResponse: true })
* .then((message) => console.log(`Reply sent with content ${message.content}`))
* .catch(console.error);
* @example
@@ -122,7 +122,7 @@ class InteractionResponses {
});
this.replied = true;
- return options.fetchReply ? this.fetchReply() : new InteractionResponse(this);
+ return options.fetchResponse ? this.fetchResponse() : new InteractionResponse(this);
}
/**
@@ -132,32 +132,32 @@ class InteractionResponses {
* @returns {Promise}
* @example
* // Fetch the initial reply to this interaction
- * interaction.fetchReply()
+ * interaction.fetchResponse()
* .then(reply => console.log(`Replied with ${reply.content}`))
* .catch(console.error);
*/
- fetchReply(message = '@original') {
+ fetchResponse(message = '@original') {
return this.webhook.fetchMessage(message);
}
/**
- * Options that can be passed into {@link InteractionResponses#editReply}.
- * @typedef {WebhookMessageEditOptions} InteractionEditReplyOptions
+ * Options that can be passed into {@link InteractionResponses#editResponse}.
+ * @typedef {WebhookMessageEditOptions} InteractionEditResponseOptions
* @property {MessageResolvable|'@original'} [message='@original'] The response to edit
*/
/**
* Edits a reply to this interaction.
* @see Webhook#editMessage
- * @param {string|MessagePayload|InteractionEditReplyOptions} options The new options for the message
+ * @param {string|MessagePayload|InteractionEditResponseOptions} options The new options for the message
* @returns {Promise}
* @example
* // Edit the initial reply to this interaction
- * interaction.editReply('New content')
+ * interaction.editResponse('New content')
* .then(console.log)
* .catch(console.error);
*/
- async editReply(options) {
+ async editResponse(options) {
if (!this.deferred && !this.replied) throw new DiscordjsError(ErrorCodes.InteractionNotReplied);
const msg = await this.webhook.editMessage(options.message ?? '@original', options);
this.replied = true;
@@ -171,11 +171,11 @@ class InteractionResponses {
* @returns {Promise}
* @example
* // Delete the initial reply to this interaction
- * interaction.deleteReply()
+ * interaction.deleteResponse()
* .then(console.log)
* .catch(console.error);
*/
- async deleteReply(message = '@original') {
+ async deleteResponse(message = '@original') {
await this.webhook.deleteMessage(message);
}
@@ -191,15 +191,15 @@ class InteractionResponses {
/**
* Defers an update to the message to which the component was attached.
- * @param {InteractionDeferUpdateOptions} [options] Options for deferring the update to this interaction
+ * @param {InteractionDeferMessageUpdateOptions} [options] Options for deferring the update to this interaction
* @returns {Promise}
* @example
* // Defer updating and reset the component's loading state
- * interaction.deferUpdate()
+ * interaction.deferMessageUpdate()
* .then(console.log)
* .catch(console.error);
*/
- async deferUpdate(options = {}) {
+ async deferMessageUpdate(options = {}) {
if (this.deferred || this.replied) throw new DiscordjsError(ErrorCodes.InteractionAlreadyReplied);
await this.client.rest.post(Routes.interactionCallback(this.id, this.token), {
body: {
@@ -209,23 +209,23 @@ class InteractionResponses {
});
this.deferred = true;
- return options.fetchReply ? this.fetchReply() : new InteractionResponse(this, this.message?.interaction?.id);
+ return options.fetchResponse ? this.fetchResponse() : new InteractionResponse(this, this.message?.interaction?.id);
}
/**
* Updates the original message of the component on which the interaction was received on.
- * @param {string|MessagePayload|InteractionUpdateOptions} options The options for the updated message
+ * @param {string|MessagePayload|InteractionUpdateMessageOptions} options The options for the updated message
* @returns {Promise}
* @example
* // Remove the components from the message
- * interaction.update({
+ * interaction.updateMessage({
* content: "A component interaction was received",
* components: []
* })
* .then(console.log)
* .catch(console.error);
*/
- async update(options) {
+ async updateMessage(options) {
if (this.deferred || this.replied) throw new DiscordjsError(ErrorCodes.InteractionAlreadyReplied);
let messagePayload;
@@ -244,7 +244,7 @@ class InteractionResponses {
});
this.replied = true;
- return options.fetchReply ? this.fetchReply() : new InteractionResponse(this, this.message.interaction?.id);
+ return options.fetchResponse ? this.fetchResponse() : new InteractionResponse(this, this.message.interaction?.id);
}
/**
@@ -317,12 +317,12 @@ class InteractionResponses {
const props = [
'deferReply',
'reply',
- 'fetchReply',
- 'editReply',
- 'deleteReply',
+ 'fetchResponse',
+ 'editResponse',
+ 'deleteResponse',
'followUp',
- 'deferUpdate',
- 'update',
+ 'deferMessageUpdate',
+ 'updateMessage',
'showModal',
'sendPremiumRequired',
'awaitModalSubmit',
diff --git a/packages/discord.js/typings/index.d.ts b/packages/discord.js/typings/index.d.ts
index a7b00f808e01..3f9a45db2f48 100644
--- a/packages/discord.js/typings/index.d.ts
+++ b/packages/discord.js/typings/index.d.ts
@@ -572,16 +572,16 @@ export abstract class CommandInteraction e
public inCachedGuild(): this is CommandInteraction<'cached'>;
public inRawGuild(): this is CommandInteraction<'raw'>;
public deferReply(
- options: InteractionDeferReplyOptions & { fetchReply: true },
+ options: InteractionDeferReplyOptions & { fetchResponse: true },
): Promise>>;
public deferReply(options?: InteractionDeferReplyOptions): Promise>>;
- public deleteReply(message?: MessageResolvable | '@original'): Promise;
- public editReply(
- options: string | MessagePayload | InteractionEditReplyOptions,
+ public deleteResponse(message?: MessageResolvable | '@original'): Promise;
+ public editResponse(
+ options: string | MessagePayload | InteractionEditResponseOptions,
): Promise>>;
- public fetchReply(message?: Snowflake | '@original'): Promise>>;
+ public fetchResponse(message?: Snowflake | '@original'): Promise>>;
public followUp(options: string | MessagePayload | InteractionReplyOptions): Promise>>;
- public reply(options: InteractionReplyOptions & { fetchReply: true }): Promise>>;
+ public reply(options: InteractionReplyOptions & { fetchResponse: true }): Promise>>;
public reply(
options: string | MessagePayload | InteractionReplyOptions,
): Promise>>;
@@ -2276,26 +2276,30 @@ export class MessageComponentInteraction e
public inCachedGuild(): this is MessageComponentInteraction<'cached'>;
public inRawGuild(): this is MessageComponentInteraction<'raw'>;
public deferReply(
- options: InteractionDeferReplyOptions & { fetchReply: true },
+ options: InteractionDeferReplyOptions & { fetchResponse: true },
): Promise>>;
public deferReply(options?: InteractionDeferReplyOptions): Promise>>;
- public deferUpdate(
- options: InteractionDeferUpdateOptions & { fetchReply: true },
+ public deferMessageUpdate(
+ options: InteractionDeferMessageUpdateOptions & { fetchResponse: true },
): Promise>>;
- public deferUpdate(options?: InteractionDeferUpdateOptions): Promise>>;
- public deleteReply(message?: MessageResolvable | '@original'): Promise;
- public editReply(
- options: string | MessagePayload | InteractionEditReplyOptions,
+ public deferMessageUpdate(
+ options?: InteractionDeferMessageUpdateOptions,
+ ): Promise>>;
+ public deleteResponse(message?: MessageResolvable | '@original'): Promise;
+ public editResponse(
+ options: string | MessagePayload | InteractionEditResponseOptions,
): Promise>>;
- public fetchReply(message?: Snowflake | '@original'): Promise>>;
+ public fetchResponse(message?: Snowflake | '@original'): Promise>>;
public followUp(options: string | MessagePayload | InteractionReplyOptions): Promise>>;
- public reply(options: InteractionReplyOptions & { fetchReply: true }): Promise>>;
+ public reply(options: InteractionReplyOptions & { fetchResponse: true }): Promise>>;
public reply(
options: string | MessagePayload | InteractionReplyOptions,
): Promise>>;
- public update(options: InteractionUpdateOptions & { fetchReply: true }): Promise>>;
- public update(
- options: string | MessagePayload | InteractionUpdateOptions,
+ public updateMessage(
+ options: InteractionUpdateMessageOptions & { fetchResponse: true },
+ ): Promise>>;
+ public updateMessage(
+ options: string | MessagePayload | InteractionUpdateMessageOptions,
): Promise>>;
public showModal(
modal:
@@ -2382,7 +2386,7 @@ export type MessagePayloadOption =
| WebhookMessageCreateOptions
| WebhookMessageEditOptions
| InteractionReplyOptions
- | InteractionUpdateOptions;
+ | InteractionUpdateMessageOptions;
export class MessagePayload {
public constructor(target: MessageTarget, options: MessagePayloadOption);
@@ -2465,9 +2469,9 @@ export interface ModalMessageModalSubmitInteraction {
message: Message>;
channelId: Snowflake;
- update(options: InteractionUpdateOptions & { fetchReply: true }): Promise;
- update(
- options: string | MessagePayload | InteractionUpdateOptions,
+ updateMessage(options: InteractionUpdateMessageOptions & { fetchResponse: true }): Promise;
+ updateMessage(
+ options: string | MessagePayload | InteractionUpdateMessageOptions,
): Promise>>;
inGuild(): this is ModalMessageModalSubmitInteraction<'raw' | 'cached'>;
inCachedGuild(): this is ModalMessageModalSubmitInteraction<'cached'>;
@@ -2485,24 +2489,26 @@ export class ModalSubmitInteraction extend
public message: Message> | null;
public replied: boolean;
public readonly webhook: InteractionWebhook;
- public reply(options: InteractionReplyOptions & { fetchReply: true }): Promise>>;
+ public reply(options: InteractionReplyOptions & { fetchResponse: true }): Promise>>;
public reply(
options: string | MessagePayload | InteractionReplyOptions,
): Promise>>;
- public deleteReply(message?: MessageResolvable | '@original'): Promise;
- public editReply(
- options: string | MessagePayload | InteractionEditReplyOptions,
+ public deleteResponse(message?: MessageResolvable | '@original'): Promise;
+ public editResponse(
+ options: string | MessagePayload | InteractionEditResponseOptions,
): Promise>>;
public deferReply(
- options: InteractionDeferReplyOptions & { fetchReply: true },
+ options: InteractionDeferReplyOptions & { fetchResponse: true },
): Promise>>;
public deferReply(options?: InteractionDeferReplyOptions): Promise>>;
- public fetchReply(message?: Snowflake | '@original'): Promise>>;
+ public fetchResponse(message?: Snowflake | '@original'): Promise>>;
public followUp(options: string | MessagePayload | InteractionReplyOptions): Promise>>;
- public deferUpdate(
- options: InteractionDeferUpdateOptions & { fetchReply: true },
+ public deferMessageUpdate(
+ options: InteractionDeferMessageUpdateOptions & { fetchResponse: true },
): Promise>>;
- public deferUpdate(options?: InteractionDeferUpdateOptions): Promise>>;
+ public deferMessageUpdate(
+ options?: InteractionDeferMessageUpdateOptions,
+ ): Promise>>;
/** @deprecated Sending a premium-style button is the new Discord behaviour. */
public sendPremiumRequired(): Promise;
public inGuild(): this is ModalSubmitInteraction<'raw' | 'cached'>;
@@ -6230,23 +6236,23 @@ export interface InteractionCollectorOptions<
export interface InteractionDeferReplyOptions {
ephemeral?: boolean;
- fetchReply?: boolean;
+ fetchResponse?: boolean;
}
-export interface InteractionDeferUpdateOptions extends Omit {}
+export interface InteractionDeferMessageUpdateOptions extends Omit {}
export interface InteractionReplyOptions extends BaseMessageOptions {
tts?: boolean;
ephemeral?: boolean;
- fetchReply?: boolean;
+ fetchResponse?: boolean;
flags?: BitFieldResolvable<
Extract,
MessageFlags.Ephemeral | MessageFlags.SuppressEmbeds | MessageFlags.SuppressNotifications
>;
}
-export interface InteractionUpdateOptions extends MessageEditOptions {
- fetchReply?: boolean;
+export interface InteractionUpdateMessageOptions extends MessageEditOptions {
+ fetchResponse?: boolean;
}
export interface InviteGenerationOptions {
@@ -6908,7 +6914,7 @@ export interface WebhookMessageEditOptions extends Omit {
expectAssignable>(message);
const component = await message.awaitMessageComponent({ componentType: ComponentType.Button });
expectType>(component);
- expectType>(await component.reply({ fetchReply: true }));
+ expectType>(await component.reply({ fetchResponse: true }));
const buttonCollector = message.createMessageComponentCollector({ componentType: ComponentType.Button });
expectType>>(buttonCollector);
@@ -1786,36 +1786,36 @@ client.on('interactionCreate', async interaction => {
expectType(interaction.component);
expectType>(interaction.message);
expectType(interaction.guild);
- expectType>>(interaction.reply({ content: 'a', fetchReply: true }));
- expectType>>(interaction.deferReply({ fetchReply: true }));
- expectType>>(interaction.editReply({ content: 'a' }));
- expectType>>(interaction.fetchReply());
- expectType>>(interaction.update({ content: 'a', fetchReply: true }));
- expectType>>(interaction.deferUpdate({ fetchReply: true }));
+ expectType>>(interaction.reply({ content: 'a', fetchResponse: true }));
+ expectType>>(interaction.deferReply({ fetchResponse: true }));
+ expectType>>(interaction.editResponse({ content: 'a' }));
+ expectType>>(interaction.fetchResponse());
+ expectType>>(interaction.updateMessage({ content: 'a', fetchResponse: true }));
+ expectType>>(interaction.deferMessageUpdate({ fetchResponse: true }));
expectType>>(interaction.followUp({ content: 'a' }));
} else if (interaction.inRawGuild()) {
expectAssignable(interaction);
expectType(interaction.component);
expectType>(interaction.message);
expectType(interaction.guild);
- expectType>>(interaction.reply({ content: 'a', fetchReply: true }));
- expectType>>(interaction.deferReply({ fetchReply: true }));
- expectType>>(interaction.editReply({ content: 'a' }));
- expectType>>(interaction.fetchReply());
- expectType>>(interaction.update({ content: 'a', fetchReply: true }));
- expectType>>(interaction.deferUpdate({ fetchReply: true }));
+ expectType>>(interaction.reply({ content: 'a', fetchResponse: true }));
+ expectType>>(interaction.deferReply({ fetchResponse: true }));
+ expectType>>(interaction.editResponse({ content: 'a' }));
+ expectType>>(interaction.fetchResponse());
+ expectType>>(interaction.updateMessage({ content: 'a', fetchResponse: true }));
+ expectType>>(interaction.deferMessageUpdate({ fetchResponse: true }));
expectType>>(interaction.followUp({ content: 'a' }));
} else if (interaction.inGuild()) {
expectAssignable(interaction);
expectType(interaction.component);
expectType(interaction.message);
expectType(interaction.guild);
- expectType>(interaction.reply({ content: 'a', fetchReply: true }));
- expectType>(interaction.deferReply({ fetchReply: true }));
- expectType>(interaction.editReply({ content: 'a' }));
- expectType>(interaction.fetchReply());
- expectType>(interaction.update({ content: 'a', fetchReply: true }));
- expectType>(interaction.deferUpdate({ fetchReply: true }));
+ expectType>(interaction.reply({ content: 'a', fetchResponse: true }));
+ expectType>(interaction.deferReply({ fetchResponse: true }));
+ expectType>(interaction.editResponse({ content: 'a' }));
+ expectType>(interaction.fetchResponse());
+ expectType>(interaction.updateMessage({ content: 'a', fetchResponse: true }));
+ expectType>(interaction.deferMessageUpdate({ fetchResponse: true }));
expectType>(interaction.followUp({ content: 'a' }));
}
}
@@ -1849,26 +1849,26 @@ client.on('interactionCreate', async interaction => {
expectAssignable(interaction);
expectAssignable(interaction.guild);
expectAssignable>(interaction);
- expectType>>(interaction.reply({ content: 'a', fetchReply: true }));
- expectType>>(interaction.deferReply({ fetchReply: true }));
- expectType>>(interaction.editReply({ content: 'a' }));
- expectType>>(interaction.fetchReply());
+ expectType>>(interaction.reply({ content: 'a', fetchResponse: true }));
+ expectType>>(interaction.deferReply({ fetchResponse: true }));
+ expectType>>(interaction.editResponse({ content: 'a' }));
+ expectType>>(interaction.fetchResponse());
expectType>>(interaction.followUp({ content: 'a' }));
} else if (interaction.inRawGuild()) {
expectAssignable(interaction);
expectType(interaction.guild);
- expectType>>(interaction.reply({ content: 'a', fetchReply: true }));
- expectType>>(interaction.deferReply({ fetchReply: true }));
- expectType>>(interaction.editReply({ content: 'a' }));
- expectType>>(interaction.fetchReply());
+ expectType>>(interaction.reply({ content: 'a', fetchResponse: true }));
+ expectType>>(interaction.deferReply({ fetchResponse: true }));
+ expectType>>(interaction.editResponse({ content: 'a' }));
+ expectType>>(interaction.fetchResponse());
expectType>>(interaction.followUp({ content: 'a' }));
} else if (interaction.inGuild()) {
expectAssignable(interaction);
expectType(interaction.guild);
- expectType>(interaction.reply({ content: 'a', fetchReply: true }));
- expectType>(interaction.deferReply({ fetchReply: true }));
- expectType>(interaction.editReply({ content: 'a' }));
- expectType>(interaction.fetchReply());
+ expectType>(interaction.reply({ content: 'a', fetchResponse: true }));
+ expectType>(interaction.deferReply({ fetchResponse: true }));
+ expectType>(interaction.editResponse({ content: 'a' }));
+ expectType>(interaction.fetchResponse());
expectType>(interaction.followUp({ content: 'a' }));
}
}
@@ -1920,19 +1920,19 @@ client.on('interactionCreate', async interaction => {
expectType(interaction.component);
expectType>(interaction.message);
expectType(interaction.guild);
- expectType>>(interaction.reply({ fetchReply: true }));
+ expectType>>(interaction.reply({ fetchResponse: true }));
} else if (interaction.inRawGuild()) {
expectAssignable(interaction);
expectType(interaction.component);
expectType>(interaction.message);
expectType(interaction.guild);
- expectType>>(interaction.reply({ fetchReply: true }));
+ expectType>>(interaction.reply({ fetchResponse: true }));
} else if (interaction.inGuild()) {
expectAssignable(interaction);
expectType(interaction.component);
expectType(interaction.message);
expectAssignable(interaction.guild);
- expectType>(interaction.reply({ fetchReply: true }));
+ expectType>(interaction.reply({ fetchResponse: true }));
}
}
@@ -1948,19 +1948,19 @@ client.on('interactionCreate', async interaction => {
expectType(interaction.component);
expectType>(interaction.message);
expectType(interaction.guild);
- expectType>>(interaction.reply({ fetchReply: true }));
+ expectType>>(interaction.reply({ fetchResponse: true }));
} else if (interaction.inRawGuild()) {
expectAssignable(interaction);
expectType(interaction.component);
expectType>(interaction.message);
expectType(interaction.guild);
- expectType>>(interaction.reply({ fetchReply: true }));
+ expectType>>(interaction.reply({ fetchResponse: true }));
} else if (interaction.inGuild()) {
expectAssignable(interaction);
expectType(interaction.component);
expectType(interaction.message);
expectType(interaction.guild);
- expectType>(interaction.reply({ fetchReply: true }));
+ expectType>(interaction.reply({ fetchResponse: true }));
}
}
@@ -1972,13 +1972,13 @@ client.on('interactionCreate', async interaction => {
if (interaction.inRawGuild()) {
expectNotAssignable>(interaction);
expectAssignable(interaction);
- expectType>>(interaction.reply({ fetchReply: true }));
+ expectType>>(interaction.reply({ fetchResponse: true }));
expectType(interaction.options.getMember('test'));
expectType(interaction.options.getChannel('test', true));
expectType(interaction.options.getRole('test', true));
} else if (interaction.inCachedGuild()) {
- const msg = await interaction.reply({ fetchReply: true });
+ const msg = await interaction.reply({ fetchResponse: true });
const btn = await msg.awaitMessageComponent({ componentType: ComponentType.Button });
expectType>(msg);
@@ -1986,7 +1986,7 @@ client.on('interactionCreate', async interaction => {
expectType(interaction.options.getMember('test'));
expectAssignable(interaction);
- expectType>>(interaction.reply({ fetchReply: true }));
+ expectType>>(interaction.reply({ fetchResponse: true }));
expectType(interaction.options.getChannel('test', true));
expectType(interaction.options.getRole('test', true));
@@ -2012,7 +2012,7 @@ client.on('interactionCreate', async interaction => {
// @ts-expect-error
consumeCachedCommand(interaction);
expectType(interaction);
- expectType>(interaction.reply({ fetchReply: true }));
+ expectType>(interaction.reply({ fetchResponse: true }));
expectType(interaction.options.getMember('test'));
expectType(interaction.options.getChannel('test', true));
@@ -2066,29 +2066,29 @@ client.on('interactionCreate', async interaction => {
if (interaction.inCachedGuild()) {
expectAssignable(interaction);
expectType(interaction.guild);
- expectType>>(interaction.reply({ content: 'a', fetchReply: true }));
- expectType>>(interaction.deferReply({ fetchReply: true }));
- expectType>>(interaction.editReply({ content: 'a' }));
- expectType>>(interaction.fetchReply());
- expectType>>(interaction.deferUpdate({ fetchReply: true }));
+ expectType>>(interaction.reply({ content: 'a', fetchResponse: true }));
+ expectType>>(interaction.deferReply({ fetchResponse: true }));
+ expectType>>(interaction.editResponse({ content: 'a' }));
+ expectType>>(interaction.fetchResponse());
+ expectType>>(interaction.deferMessageUpdate({ fetchResponse: true }));
expectType>>(interaction.followUp({ content: 'a' }));
} else if (interaction.inRawGuild()) {
expectAssignable(interaction);
expectType(interaction.guild);
- expectType>>(interaction.reply({ content: 'a', fetchReply: true }));
- expectType>>(interaction.deferReply({ fetchReply: true }));
- expectType>>(interaction.editReply({ content: 'a' }));
- expectType>>(interaction.fetchReply());
- expectType>>(interaction.deferUpdate({ fetchReply: true }));
+ expectType>>(interaction.reply({ content: 'a', fetchResponse: true }));
+ expectType>>(interaction.deferReply({ fetchResponse: true }));
+ expectType>>(interaction.editResponse({ content: 'a' }));
+ expectType>>(interaction.fetchResponse());
+ expectType>>(interaction.deferMessageUpdate({ fetchResponse: true }));
expectType>>(interaction.followUp({ content: 'a' }));
} else if (interaction.inGuild()) {
expectAssignable(interaction);
expectType(interaction.guild);
- expectType>(interaction.reply({ content: 'a', fetchReply: true }));
- expectType>(interaction.deferReply({ fetchReply: true }));
- expectType>(interaction.editReply({ content: 'a' }));
- expectType>(interaction.fetchReply());
- expectType>(interaction.deferUpdate({ fetchReply: true }));
+ expectType>(interaction.reply({ content: 'a', fetchResponse: true }));
+ expectType>(interaction.deferReply({ fetchResponse: true }));
+ expectType>(interaction.editResponse({ content: 'a' }));
+ expectType>(interaction.fetchResponse());
+ expectType>(interaction.deferMessageUpdate({ fetchResponse: true }));
expectType>(interaction.followUp({ content: 'a' }));
}
}