From b763dabaa941826e635e630526ef227a16d69eec Mon Sep 17 00:00:00 2001 From: RaZe <75721601+RaZeSloth@users.noreply.github.com> Date: Wed, 22 Dec 2021 12:13:34 +0200 Subject: [PATCH] fix: Make the followUp function error more clear (#7129) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: D Trombett Co-authored-by: Antonio Román --- src/structures/interfaces/InteractionResponses.js | 1 + 1 file changed, 1 insertion(+) diff --git a/src/structures/interfaces/InteractionResponses.js b/src/structures/interfaces/InteractionResponses.js index 85026e9beae5..dbe7c2327e8a 100644 --- a/src/structures/interfaces/InteractionResponses.js +++ b/src/structures/interfaces/InteractionResponses.js @@ -162,6 +162,7 @@ class InteractionResponses { * @returns {Promise} */ followUp(options) { + if (!this.deferred && !this.replied) return Promise.reject(new Error('INTERACTION_NOT_REPLIED')); return this.webhook.send(options); }