aboutsummaryrefslogtreecommitdiff
path: root/src/context-menu-commands
diff options
context:
space:
mode:
authorIRONM00N <64110067+IRONM00N@users.noreply.github.com>2022-06-17 20:03:05 -0400
committerIRONM00N <64110067+IRONM00N@users.noreply.github.com>2022-06-17 20:03:05 -0400
commite1c613829950a534d9f45c00a033b83575be3b3c (patch)
tree2de1e5231217211ae4087c46cc74dc46c584507a /src/context-menu-commands
parent0e87bbd3940d89defcb04926587b35c8f4d1947f (diff)
downloadtanzanite-e1c613829950a534d9f45c00a033b83575be3b3c.tar.gz
tanzanite-e1c613829950a534d9f45c00a033b83575be3b3c.tar.bz2
tanzanite-e1c613829950a534d9f45c00a033b83575be3b3c.zip
remove global client variable
Diffstat (limited to 'src/context-menu-commands')
-rw-r--r--src/context-menu-commands/user/modlog.ts4
-rw-r--r--src/context-menu-commands/user/userInfo.ts2
2 files changed, 3 insertions, 3 deletions
diff --git a/src/context-menu-commands/user/modlog.ts b/src/context-menu-commands/user/modlog.ts
index 7f3103d..c78396e 100644
--- a/src/context-menu-commands/user/modlog.ts
+++ b/src/context-menu-commands/user/modlog.ts
@@ -25,8 +25,8 @@ export default class ModlogContextMenuCommand extends ContextMenuCommand {
});
await interaction.deferReply({ ephemeral: true });
- const pseudoMessage = new SlashMessage(client, interaction as any);
- pseudoMessage.util = new CommandUtil(client.commandHandler, pseudoMessage);
+ const pseudoMessage = new SlashMessage(this.client, interaction as any);
+ pseudoMessage.util = new CommandUtil(this.client.commandHandler, pseudoMessage);
void new ModlogCommand().exec(pseudoMessage, { search: interaction.targetId, hidden: false });
}
diff --git a/src/context-menu-commands/user/userInfo.ts b/src/context-menu-commands/user/userInfo.ts
index 075b681..6d7f3b6 100644
--- a/src/context-menu-commands/user/userInfo.ts
+++ b/src/context-menu-commands/user/userInfo.ts
@@ -15,7 +15,7 @@ export default class UserInfoContextMenuCommand extends ContextMenuCommand {
public override async exec(interaction: ContextMenuCommandInteraction) {
await interaction.deferReply({ ephemeral: true });
- const user = await client.users.fetch(interaction.targetId).catch(() => null);
+ const user = await this.client.users.fetch(interaction.targetId).catch(() => null);
if (!user) return interaction.reply(`⁉ I couldn't find that user`);
const guild = interaction.guild as Guild;