所以我正在尝试编写代码来踢服务器的成员。
async run (commandoMsg, userId) {
let guild = commandoMsg.guild;
//console.log(guild.members.fetch(userId));
let member = guild.members.fetch(userId);
member.kick('Kicking...')
.then(m => console.log('kicked'))
.catch(err => console.log(err));
我收到一条错误消息,提示
TypeError: member.kick is not a function
如何删除此错误?