This commit is contained in:
Expand-sys 2023-02-24 21:53:55 +11:00
parent 4e9d3e4cdd
commit 7bf97425a6

View file

@ -26,7 +26,7 @@ module.exports = {
let mcusr = interaction.options.getString("mcusername")
let collection = await dbclient.db("ntcmcbot").collection("users");
let userdb = await collection.findOne({DISCORDID: interaction.member.id})
interaction.deferReply()
let highest = "default";
switch(true) {
case interaction.member.roles.cache.has(process.env.MCSTAFF_ROLE):
@ -75,7 +75,7 @@ module.exports = {
}
let res = await rcon.send(`lp user ${mcusr} group add ${highest}`);
console.log(res)
await sendResponse(interaction, `added ${mcusr} to the role ${highest}`);
await interaction.editReply(`added ${mcusr} to the role ${highest}`);
await rcon.end();
}
}