add channels pill

This commit is contained in:
derpystuff 2024-04-06 15:02:51 +02:00
parent 274a3b6bcc
commit b67d4d40a4

View file

@ -21,7 +21,6 @@ module.exports = {
run: async (context) => { run: async (context) => {
try{ try{
const emojis = context.message.guild.emojis const emojis = context.message.guild.emojis
const animojis = emojis.filter(emoji => emoji.animated).length
const channels = context.message.guild.channels const channels = context.message.guild.channels
@ -40,8 +39,9 @@ module.exports = {
pills.push(iconPill("user_multiple", context.guild.memberCount)) pills.push(iconPill("user_multiple", context.guild.memberCount))
if(g.premiumSubscriptionCount >= 1) pills.push(iconPill("boost", g.premiumSubscriptionCount)) if(g.premiumSubscriptionCount >= 1) pills.push(iconPill("boost", g.premiumSubscriptionCount))
if(g.roles.length >= 2) pills.push(iconPill("user_shield", `${g.roles.length} Roles`)) if(g.roles.length >= 2) pills.push(iconPill("user_shield", `${g.roles.length} Roles`))
if(g.owner) pills.push(`${icon("user_king")} <@${g.owner.id}>`)
if(emojis.length >= 1) pills.push(iconPill("emoji", emojis.length)) if(emojis.length >= 1) pills.push(iconPill("emoji", emojis.length))
if(channels.length >= 1) pills.push(iconPill("channel", g.channels.length))
if(g.owner) pills.push(`${icon("user_king")} <@${g.owner.id}>`)
let guildCard = createEmbed("default", context, { let guildCard = createEmbed("default", context, {
description: `${icon("home")} **${g.name}** ${highlight(`(${g.id})`)}\n${pills.join(' ')}\n\n${icon("calendar")} **Server created** ${timestamp(g.createdAt, "f")}`, description: `${icon("home")} **${g.name}** ${highlight(`(${g.id})`)}\n${pills.join(' ')}\n\n${icon("calendar")} **Server created** ${timestamp(g.createdAt, "f")}`,
@ -63,9 +63,6 @@ module.exports = {
if(stageChannels >= 1) lines.push(`Stage Channels ${stageChannels}`) if(stageChannels >= 1) lines.push(`Stage Channels ${stageChannels}`)
if(categoryChannels >= 1) lines.push(`Categories ${categoryChannels}`) if(categoryChannels >= 1) lines.push(`Categories ${categoryChannels}`)
lines.push("")
lines.push(`Total ${channels.length}`)
guildCard.fields.push({ guildCard.fields.push({
name: `${icon("channel")} Channels`, name: `${icon("channel")} Channels`,
value: codeblock("py", lines), value: codeblock("py", lines),