Skip to content

Commit

Permalink
fix(InteractionResponses): mark replied true for followUps (#10688)
Browse files Browse the repository at this point in the history
fix: mark replied true for followUps

Co-authored-by: Jiralite <33201955+Jiralite@users.noreply.github.com>
  • Loading branch information
imnaiyar and Jiralite committed Jan 12, 2025
1 parent efa50fc commit 32dff01
Showing 1 changed file with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -272,9 +272,11 @@ class InteractionResponses {
* @param {string|MessagePayload|InteractionReplyOptions} options The options for the reply
* @returns {Promise<Message>}
*/
followUp(options) {
async followUp(options) {
if (!this.deferred && !this.replied) return Promise.reject(new DiscordjsError(ErrorCodes.InteractionNotReplied));
return this.webhook.send(options);
const msg = await this.webhook.send(options);
this.replied = true;
return msg;
}

/**
Expand Down

0 comments on commit 32dff01

Please sign in to comment.