Answers for "discord.js unmute script"

0

discord.js unmute script

client.on('message', message => {
    if (message.content.startsWith(prefix + 'unmute')) {
        if (message.member.hasPermission('MANAGE_ROLES')) {
            const role = message.guild.roles.cache.find(role => role.name === 'Muted');
            const member = message.mentions.members.first();
            member.roles.remove(role);
            message.channel.send(member + ' Has Been Unmuted');

        } else {
            message.channel.send("Please Mention Who To Unute")
        }
    }
})
Posted by: Guest on December-27-2020

Code answers related to "Javascript"

Browse Popular Code Answers by Language