const { WelcomeChannel } = require("discord.js"); const { userMention } = require("@discordjs/builders"); module.exports = { name: 'guildMemberAdd', async execute(member, guild) { await guild.fetchWelcomeScreen() .then(() => { const channel = this.welcomeChannels; channel.forEach(async element => { const nickname = memberNicknameMention(member.id); await interaction.reply('Bienvenue ' + nickname + ' ! Mets toi à l\'aise, il y a des bières dans le frigo.'); }) }) .catch(console.error); }, };