фикс...

This commit is contained in:
JonnyBro 2022-02-15 01:34:39 +05:00
parent 8ccf048125
commit 744b4e1f01

View file

@ -34,14 +34,14 @@ class Poll extends Command {
if (tmsg.content.toLowerCase() === message.translate("common:NO").toLowerCase()) { if (tmsg.content.toLowerCase() === message.translate("common:NO").toLowerCase()) {
tmsg.delete(); tmsg.delete();
msg.delete(); msg.delete();
message.delete();
collector.stop(true); collector.stop(true);
message.delete();
} }
if (tmsg.content.toLowerCase() === message.translate("common:YES").toLowerCase()) { if (tmsg.content.toLowerCase() === message.translate("common:YES").toLowerCase()) {
tmsg.delete(); tmsg.delete();
msg.delete(); msg.delete();
message.delete();
const tmsg1 = await message.sendT("moderation/announcement:MENTION_TYPE_PROMPT"); const tmsg1 = await message.sendT("moderation/announcement:MENTION_TYPE_PROMPT");
const filter = m => m.author.id === message.author.id; const filter = m => m.author.id === message.author.id;
@ -65,12 +65,12 @@ class Poll extends Command {
c.stop(true); c.stop(true);
} }
}); });
c.on("end", (collected, reason) => { c.on("end", (collected, reason) => {
if (reason === "time") { if (reason === "time") return message.error("misc:TIMES_UP");
message.delete();
return message.error("misc:TIMES_UP");
}
}); });
message.delete();
} }
}); });