diff options
author | IRONM00N <64110067+IRONM00N@users.noreply.github.com> | 2022-01-15 18:12:05 -0500 |
---|---|---|
committer | IRONM00N <64110067+IRONM00N@users.noreply.github.com> | 2022-01-15 18:12:05 -0500 |
commit | dc273dd2801ba54ecb74fb1be75bc64eff5d551c (patch) | |
tree | 9b33922a1e599ba396b1da5b2b5449d4ae67d47d | |
parent | 979170bafab1444353fc330627d8bfd0d8b68aff (diff) | |
download | tanzanite-dc273dd2801ba54ecb74fb1be75bc64eff5d551c.tar.gz tanzanite-dc273dd2801ba54ecb74fb1be75bc64eff5d551c.tar.bz2 tanzanite-dc273dd2801ba54ecb74fb1be75bc64eff5d551c.zip |
make button ban response fetch user instead of member
-rw-r--r-- | src/lib/common/AutoMod.ts | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/lib/common/AutoMod.ts b/src/lib/common/AutoMod.ts index a1f2f1e..7a30820 100644 --- a/src/lib/common/AutoMod.ts +++ b/src/lib/common/AutoMod.ts @@ -308,20 +308,20 @@ export class AutoMod { evidence: (interaction.message as BushMessage).url ?? undefined }); - const victimFormatted = victim ?? userId; + const victimUserFormatted = (await util.resolveNonCachedUser(userId))?.tag ?? userId; if (result === banResponse.SUCCESS) return interaction.reply({ - content: `${util.emojis.success} Successfully banned **${victimFormatted}**.`, + content: `${util.emojis.success} Successfully banned **${victimUserFormatted}**.`, ephemeral: true }); else if (result === banResponse.DM_ERROR) return interaction.reply({ - content: `${util.emojis.warn} Banned ${victimFormatted} however I could not send them a dm.`, + content: `${util.emojis.warn} Banned ${victimUserFormatted} however I could not send them a dm.`, ephemeral: true }); else return interaction.reply({ - content: `${util.emojis.error} Could not ban **${victimFormatted}**: \`${result}\` .`, + content: `${util.emojis.error} Could not ban **${victimUserFormatted}**: \`${result}\` .`, ephemeral: true }); } |