Untitled

mail@pastecode.io avatar
unknown
plain_text
3 years ago
473 B
15
Indexable
Never
client.on('guildMemberAdd',  (member) => {
  
  let ch1 = db.get(`channel-${member.guild.id}`);
  let ch = client.channels.cache.get(ch1);
  
  let embed = new Discord.MessageEmbed()
  .setAuthor(`Welcome to ${member.guild.name}`, member.guild.iconURL({dynamic:true}))
  .addField('Username:', member.user.tag)
  .addField('Account created', member.user.createdAt)
  .setColor('random')
  .addField('Position', member.guild.memberCount + ' Members')
  ch.send(embed)
  
});