aboutsummaryrefslogtreecommitdiff
path: root/src/listeners/bush
diff options
context:
space:
mode:
authorIRONM00N <64110067+IRONM00N@users.noreply.github.com>2022-05-24 18:29:57 -0400
committerIRONM00N <64110067+IRONM00N@users.noreply.github.com>2022-05-24 18:29:57 -0400
commit9f5d9da2a37ecfec412b149ec7dc385ab7b6a98c (patch)
tree4b95a06ff6991207ab8b8e93f0bca26e24a97f80 /src/listeners/bush
parent6b8115ab1ec94d4330019fc7a93e094d9d64c48e (diff)
downloadtanzanite-9f5d9da2a37ecfec412b149ec7dc385ab7b6a98c.tar.gz
tanzanite-9f5d9da2a37ecfec412b149ec7dc385ab7b6a98c.tar.bz2
tanzanite-9f5d9da2a37ecfec412b149ec7dc385ab7b6a98c.zip
fix: breaking changes
Diffstat (limited to 'src/listeners/bush')
-rw-r--r--src/listeners/bush/appealListener.ts19
-rw-r--r--src/listeners/bush/joinAutoBan.ts2
-rw-r--r--src/listeners/bush/supportThread.ts2
-rw-r--r--src/listeners/bush/userUpdateAutoBan.ts2
4 files changed, 12 insertions, 13 deletions
diff --git a/src/listeners/bush/appealListener.ts b/src/listeners/bush/appealListener.ts
index b50b3c5..64979b5 100644
--- a/src/listeners/bush/appealListener.ts
+++ b/src/listeners/bush/appealListener.ts
@@ -36,10 +36,7 @@ export default class AppealListener extends BushListener {
.setTitle(
`${message.embeds[0].fields!.find((f) => f.name === 'What type of punishment are you appealing?')!.value} appeal`
)
- .addFields({
- name: '» User Information',
- value: 'Unable to fetch author, ID was likely invalid'
- })
+ .addFields([{ name: '» User Information', value: 'Unable to fetch author, ID was likely invalid' }])
]
});
@@ -70,12 +67,14 @@ export default class AppealListener extends BushListener {
if (member.roles.cache.size > 1) UserInfoCommand.generateRolesField(embed, member);
}
- embed.addFields({
- name: '» Latest Modlogs',
- value: latestModlogs.length
- ? latestModlogs.map((ml) => ModlogCommand.generateModlogInfo(ml, false)).join(ModlogCommand.separator)
- : 'No Modlogs Found'
- });
+ embed.addFields([
+ {
+ name: '» Latest Modlogs',
+ value: latestModlogs.length
+ ? latestModlogs.map((ml) => ModlogCommand.generateModlogInfo(ml, false)).join(ModlogCommand.separator)
+ : 'No Modlogs Found'
+ }
+ ]);
await thread.send({ embeds: [embed] });
}
diff --git a/src/listeners/bush/joinAutoBan.ts b/src/listeners/bush/joinAutoBan.ts
index c258877..0b38766 100644
--- a/src/listeners/bush/joinAutoBan.ts
+++ b/src/listeners/bush/joinAutoBan.ts
@@ -21,7 +21,7 @@ export default class JoinAutoBanListener extends BushListener {
if (eval(code)) {
const res = await member.bushBan({
reason: '[AutoBan] Impersonation is not allowed.',
- moderator: member.guild.me!
+ moderator: member.guild.members.me!
});
if (!['success', 'failed to dm'].includes(res)) {
diff --git a/src/listeners/bush/supportThread.ts b/src/listeners/bush/supportThread.ts
index 23c1e44..2eb8dc9 100644
--- a/src/listeners/bush/supportThread.ts
+++ b/src/listeners/bush/supportThread.ts
@@ -32,7 +32,7 @@ export default class SupportThreadListener extends BushListener {
assert(message.channel instanceof BushTextChannel);
- if (!message.channel.permissionsFor(message.guild.me!).has(PermissionFlagsBits.CreatePublicThreads)) return;
+ if (!message.channel.permissionsFor(message.guild.members.me!).has(PermissionFlagsBits.CreatePublicThreads)) return;
const thread = await message
.startThread({
name: `Support - ${message.author.username}#${message.author.discriminator}`,
diff --git a/src/listeners/bush/userUpdateAutoBan.ts b/src/listeners/bush/userUpdateAutoBan.ts
index e3fba02..68dfa38 100644
--- a/src/listeners/bush/userUpdateAutoBan.ts
+++ b/src/listeners/bush/userUpdateAutoBan.ts
@@ -27,7 +27,7 @@ export default class UserUpdateAutoBanListener extends BushListener {
const res = await member.bushBan({
reason: '[AutoBan] Impersonation is not allowed.',
- moderator: member.guild.me!
+ moderator: member.guild.members.me!
});
if (!['success', 'failed to dm'].includes(res)) {