From 49a75828838b63abaa37315606eabd3adf5c1778 Mon Sep 17 00:00:00 2001 From: powermaker450 Date: Sun, 13 Oct 2024 15:52:31 -0400 Subject: [PATCH] Display users better --- src/commands/confess.ts | 2 +- src/commands/confessbanlist.ts | 5 +---- src/main.ts | 4 +--- 3 files changed, 3 insertions(+), 8 deletions(-) diff --git a/src/commands/confess.ts b/src/commands/confess.ts index 0b27003..7294c1a 100644 --- a/src/commands/confess.ts +++ b/src/commands/confess.ts @@ -99,7 +99,7 @@ export async function execute(interaction: CommandInteraction) { .addFields( { name: "Author", - value: interaction.user.displayName + value: `<@${interaction.user.id}>` }, { name: "Author ID", diff --git a/src/commands/confessbanlist.ts b/src/commands/confessbanlist.ts index 1cbd487..7033937 100644 --- a/src/commands/confessbanlist.ts +++ b/src/commands/confessbanlist.ts @@ -22,7 +22,6 @@ import { SlashCommandBuilder } from "discord.js"; import { dt } from "../main"; -import { BotClient } from "../bot"; export const data = new SlashCommandBuilder() .setName("confessbanlist") @@ -37,9 +36,7 @@ export async function execute(interaction: CommandInteraction) { : "There are no banned members."; for (const member of bannedMembers) { - const identifiedMember = await BotClient.users.fetch(member.user); - - content += `\n${identifiedMember.displayName} | \`${member.confessionId}\``; + content += `\n<@${member.user} | \`${member.confessionId}\``; } return interaction.reply({ diff --git a/src/main.ts b/src/main.ts index 8ab9f5f..3d5e169 100644 --- a/src/main.ts +++ b/src/main.ts @@ -23,8 +23,6 @@ import { ComponentType, EmbedBuilder, Events, - Interaction, - ModalSubmitInteraction, TextChannel } from "discord.js"; import { BotClient, BOT_TOKEN, deployCommands } from "./bot"; @@ -133,7 +131,7 @@ BotClient.on(Events.InteractionCreate, async interaction => { .addFields( { name: "Author", - value: interaction.user.displayName + value: `<@${interaction.user.id}>` }, { name: "Author ID",