Added new formatter

This commit is contained in:
2024-10-18 11:25:05 +02:00
parent ce0b3ecd22
commit 57b3710c41
4 changed files with 18 additions and 8 deletions

View File

@@ -1,17 +1,18 @@
import { GuildMember, userMention } from "discord.js"
import { userMention } from "discord.js"
import { embedColor } from "~/config/options.js"
import { IEvent } from "~/interfaces"
import { dateTimeFormatter } from "~/utils/Functions/intlFormaters"
import logToChannel from "~/utils/Functions/logtochannel.js"
export default {
event: "guildMemberAdd",
execute(member: GuildMember) {
execute(member) {
if (process.env.NODE_ENV === "dev") return
logToChannel("bot", {
embeds: [{
title: "New Member",
description: userMention(member.id) + " has joined the server.\n" +
"Account created: " + member.user.createdAt.toLocaleString(),
"Account created: " + dateTimeFormatter.format(member.user.createdAt),
color: embedColor,
thumbnail: {
url: member.user.avatarURL() || ""