Fix ban command

This commit is contained in:
= 2021-11-25 13:33:30 +01:00
parent 77ace4109f
commit 438ab69e31

View file

@ -193,7 +193,7 @@ client.on("interactionCreate", (int) => {
var mem2 = int.guild.members.cache.get(int.options.getUser("user").id);
var reason = "No reason specified.";
if(int.options.getString("reason") !== null) reason = int.options.getString("reason");
mem2.ban(reason).then(() => {
mem2.ban({reason}).then(() => {
int.reply("Successfully banned <@!" + int.options.getUser("user").id + "> with reason `" + reason + "`.");
}).catch(e => {
int.reply("An error occured with my code, please report this to " + Eco.tag + " or " + Helixu.tag + ": ```js\n" + e.stack + "```");