3
0
Fork 0
mirror of https://github.com/ZeppelinBot/Zeppelin.git synced 2025-03-15 05:41:51 +00:00

Fix warn notification sometimes triggering on the bot's own reaction

This commit is contained in:
Dragory 2020-10-20 17:47:49 +03:00
parent a8b105bdec
commit 285cd2bcd8
No known key found for this signature in database
GPG key ID: 5F387BA66DF8AAC1

View file

@ -71,7 +71,7 @@ export const WarnCmd = modActionsCmd({
config.warn_notify_message.replace("{priorWarnings}", `${priorWarnAmount}`),
);
const reply = await waitForReaction(pluginData.client, tooManyWarningsMsg, ["✅", "❌"]);
const reply = await waitForReaction(pluginData.client, tooManyWarningsMsg, ["✅", "❌"], msg.author.id);
tooManyWarningsMsg.delete();
if (!reply || reply.name === "❌") {
msg.channel.createMessage(errorMessage("Warn cancelled by moderator"));