mirror of
https://github.com/darksaid98/cadence-discord-bot.git
synced 2026-12-02 14:38:49 +00:00
24 lines
654 B
TypeScript
24 lines
654 B
TypeScript
import { Events, Guild } from 'discord.js';
|
|
import { v4 as uuidv4 } from 'uuid';
|
|
|
|
import loggerModule from '../../services/logger';
|
|
|
|
module.exports = {
|
|
name: Events.GuildCreate,
|
|
isDebug: false,
|
|
once: false,
|
|
execute: async (guild: Guild) => {
|
|
const executionId = uuidv4();
|
|
const logger = loggerModule.child({
|
|
source: 'guildCreate.js',
|
|
module: 'event',
|
|
name: 'guildCreate',
|
|
executionId: executionId,
|
|
shardId: guild.shardId,
|
|
guildId: guild.id
|
|
});
|
|
|
|
logger.info(`Added to guild '${guild.id}' with ${guild.memberCount} members.`);
|
|
}
|
|
};
|