📌  相关文章
📜  如何使某人静音 discord.js - 任何代码示例

📅  最后修改于: 2022-03-11 14:58:34.047000             🧑  作者: Mango

代码示例1
// get the role by id:
const mutedRole = message.guild.roles.cache.get('');

// or, if you can't get the id:
const mutedRole = message.guild.roles.cache.find(
 (role) => role.name === 'Muted'
);

// if there is no `Muted` role, send an error
if (!mutedRole)
 return message.channel.send('There is no Muted role on this server');