Added new formatter
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
import { ChatInputCommandInteraction } from "discord.js"
|
||||
import { devMessage, embedColor } from "~/config/options.js"
|
||||
import { IGuildData } from "~/interfaces"
|
||||
import { numberFormatter } from "~/utils/Functions/intlFormaters.js"
|
||||
import { dateTimeFormatter, numberFormatter } from "~/utils/Functions/intlFormaters.js"
|
||||
import { getGuild, getIGN, getPlayer, getUUID, guildLevel } from "~/utils/Hypixel.js"
|
||||
|
||||
export default async function guildInfo(interaction: ChatInputCommandInteraction): Promise<void> {
|
||||
@@ -111,7 +111,7 @@ export default async function guildInfo(interaction: ChatInputCommandInteraction
|
||||
const guildExp = numberFormatter.format(guildExpUnformatted)
|
||||
const guildLvl = guildLevel(guildExpUnformatted)
|
||||
const guildMembers = guild!.members
|
||||
const guildCreatedTime = guildCreated.toLocaleString("hr-HR", {})
|
||||
const guildCreatedTime = dateTimeFormatter.format(guildCreated)
|
||||
|
||||
const guildOwner = guildMembers.find(m => m.rank === "Guild Master")!.uuid
|
||||
const guildOwnerName = await getIGN(guildOwner)
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import { ChatInputCommandInteraction } from "discord.js"
|
||||
import { devMessage, embedColor } from "~/config/options.js"
|
||||
import { numberFormatter } from "~/utils/Functions/intlFormaters.js"
|
||||
import { dateTimeFormatter, numberFormatter } from "~/utils/Functions/intlFormaters.js"
|
||||
import { getGuild, getHeadURL, getPlayer, getUUID } from "~/utils/Hypixel.js"
|
||||
|
||||
export default async function guildMember(interaction: ChatInputCommandInteraction): Promise<void> {
|
||||
@@ -112,7 +112,7 @@ export default async function guildMember(interaction: ChatInputCommandInteracti
|
||||
|
||||
const guildMemberJoinMS = guildMember!.joined
|
||||
const guildMemberJoinTime = new Date(guildMemberJoinMS)
|
||||
const guildMemberJoin = guildMemberJoinTime.toLocaleString("hr-HR", {})
|
||||
const guildMemberJoin = dateTimeFormatter.format(guildMemberJoinTime)
|
||||
|
||||
await interaction.editReply({
|
||||
embeds: [{
|
||||
|
||||
Reference in New Issue
Block a user