client.on('guildMemberAdd', member => {
const channel = member.guild.channels.cache.find(channel => channel.name === "welcome");
if(!channel)return;
channel.send(`Hey, Welcome to our server, ${member}, please checkout rules and information! UwU`);
channel.send('https://cdn.discordapp.com/attachments/717031584007585844/766485286552993792/Photo_1602811864863.png');
guildMember.roles.add(guildMember.guild.roles.cache.find(role => role.name === "Members"));
});
控制台中没有显示错误!之前相同的代码可以正常工作,但是idk发生了什么却不起作用。哦,还有一件事昨天,当问题开始出现时,我正在安装slappey,MongoDB和idk,这是因为我没有托管我的bot三天,然后今天又托管了它,并看到了这个问题。