mirror of
https://github.com/arthur-pbty/xiao.git
synced 2026-06-03 23:36:43 +02:00
Show guild owner in join logs
This commit is contained in:
@@ -130,13 +130,15 @@ client.on('guildCreate', async guild => {
|
||||
}
|
||||
const joinLeaveChannel = await client.fetchJoinLeaveChannel();
|
||||
if (joinLeaveChannel) {
|
||||
if (!guild.members.cache.has(guild.ownerID)) await guild.members.fetch(guild.ownerID);
|
||||
const embed = new MessageEmbed()
|
||||
.setColor(0x7CFC00)
|
||||
.setThumbnail(guild.iconURL({ format: 'png' }))
|
||||
.setTitle(`Joined ${guild.name}!`)
|
||||
.setFooter(`ID: ${guild.id}`)
|
||||
.setTimestamp()
|
||||
.addField('❯ Members', formatNumber(guild.memberCount));
|
||||
.addField('❯ Members', formatNumber(guild.memberCount))
|
||||
.addField('❯ Owner', guild.owner.user.tag);
|
||||
await joinLeaveChannel.send({ embed });
|
||||
}
|
||||
});
|
||||
|
||||
+1
-1
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "xiao",
|
||||
"version": "120.0.0",
|
||||
"version": "120.0.1",
|
||||
"description": "Your personal server companion.",
|
||||
"main": "Xiao.js",
|
||||
"scripts": {
|
||||
|
||||
Reference in New Issue
Block a user