aboutsummaryrefslogtreecommitdiff
path: root/src/listeners/member-custom
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/listeners/member-custom
parent0e87bbd3940d89defcb04926587b35c8f4d1947f (diff)
downloadtanzanite-e1c613829950a534d9f45c00a033b83575be3b3c.tar.gz
tanzanite-e1c613829950a534d9f45c00a033b83575be3b3c.tar.bz2
tanzanite-e1c613829950a534d9f45c00a033b83575be3b3c.zip
remove global client variable
Diffstat (limited to 'src/listeners/member-custom')
-rw-r--r--src/listeners/member-custom/bushPurge.ts4
-rw-r--r--src/listeners/member-custom/bushUpdateModlog.ts12
-rw-r--r--src/listeners/member-custom/bushUpdateSettings.ts6
3 files changed, 14 insertions, 8 deletions
diff --git a/src/listeners/member-custom/bushPurge.ts b/src/listeners/member-custom/bushPurge.ts
index ea30bc5..61a65e1 100644
--- a/src/listeners/member-custom/bushPurge.ts
+++ b/src/listeners/member-custom/bushPurge.ts
@@ -1,4 +1,4 @@
-import { BushListener, colors, emojis, inspectCleanRedactHaste, type BushClientEvents } from '#lib';
+import { BushListener, colors, emojis, type BushClientEvents } from '#lib';
import { EmbedBuilder } from 'discord.js';
export default class BushPurgeListener extends BushListener {
@@ -21,7 +21,7 @@ export default class BushPurgeListener extends BushListener {
embeds: m.embeds,
attachments: [...m.attachments.values()]
}));
- const haste = await inspectCleanRedactHaste(mappedMessages);
+ const haste = await this.client.utils.inspectCleanRedactHaste(mappedMessages);
const logEmbed = new EmbedBuilder()
.setColor(colors.DarkPurple)
diff --git a/src/listeners/member-custom/bushUpdateModlog.ts b/src/listeners/member-custom/bushUpdateModlog.ts
index 5e29b9a..893bec6 100644
--- a/src/listeners/member-custom/bushUpdateModlog.ts
+++ b/src/listeners/member-custom/bushUpdateModlog.ts
@@ -1,4 +1,4 @@
-import { BushListener, colors, inspectCleanRedactCodeblock, type BushClientEvents } from '#lib';
+import { BushListener, colors, type BushClientEvents } from '#lib';
import { EmbedBuilder } from 'discord.js';
export default class BushUpdateModlogListener extends BushListener {
@@ -26,8 +26,14 @@ export default class BushUpdateModlogListener extends BushListener {
{ name: '**Moderator**', value: `${moderator} (${moderator.user.tag})` },
{ name: '**ModLog Changed**', value: modlogID },
{ name: '**Value Changed**', value: key },
- { name: '**Old Value**', value: await inspectCleanRedactCodeblock(oldModlog, undefined, undefined, 1024) },
- { name: '**New Value**', value: await inspectCleanRedactCodeblock(newModlog, undefined, undefined, 1024) }
+ {
+ name: '**Old Value**',
+ value: await this.client.utils.inspectCleanRedactCodeblock(oldModlog, undefined, undefined, 1024)
+ },
+ {
+ name: '**New Value**',
+ value: await this.client.utils.inspectCleanRedactCodeblock(newModlog, undefined, undefined, 1024)
+ }
]);
return await logChannel.send({ embeds: [logEmbed] });
diff --git a/src/listeners/member-custom/bushUpdateSettings.ts b/src/listeners/member-custom/bushUpdateSettings.ts
index e367c4e..3781a8b 100644
--- a/src/listeners/member-custom/bushUpdateSettings.ts
+++ b/src/listeners/member-custom/bushUpdateSettings.ts
@@ -1,4 +1,4 @@
-import { BushListener, colors, inspectCleanRedactCodeblock, type BushClientEvents } from '#lib';
+import { BushListener, colors, type BushClientEvents } from '#lib';
import { EmbedBuilder } from 'discord.js';
export default class BushUpdateSettingsListener extends BushListener {
@@ -25,8 +25,8 @@ export default class BushUpdateSettingsListener extends BushListener {
if (moderator) logEmbed.addFields([{ name: '**Moderator**', value: `${moderator} (${moderator.user.tag})` }]);
logEmbed.addFields([
{ name: '**Setting Changed**', value: setting },
- { name: '**Old Value**', value: await inspectCleanRedactCodeblock(oldSettings, 'js', undefined, 1024) },
- { name: '**New Value**', value: await inspectCleanRedactCodeblock(newSettings, 'js', undefined, 1024) }
+ { name: '**Old Value**', value: await this.client.utils.inspectCleanRedactCodeblock(oldSettings, 'js', undefined, 1024) },
+ { name: '**New Value**', value: await this.client.utils.inspectCleanRedactCodeblock(newSettings, 'js', undefined, 1024) }
]);
return await logChannel.send({ embeds: [logEmbed] });