diff options
author | IRONM00N <64110067+IRONM00N@users.noreply.github.com> | 2022-08-10 10:27:35 -0400 |
---|---|---|
committer | IRONM00N <64110067+IRONM00N@users.noreply.github.com> | 2022-08-10 10:27:35 -0400 |
commit | 5a0046146fb2a697aead63d2af492db9f0ef9113 (patch) | |
tree | 981bf0808e465d5d692482d18437c80715ae3563 /src/lib/extensions | |
parent | f1973996dc5f1790df3f72af75732a0d250a14e2 (diff) | |
download | tanzanite-5a0046146fb2a697aead63d2af492db9f0ef9113.tar.gz tanzanite-5a0046146fb2a697aead63d2af492db9f0ef9113.tar.bz2 tanzanite-5a0046146fb2a697aead63d2af492db9f0ef9113.zip |
update discord js and discord-akairo
fix breaking changes
add unverified bot emoji to user command
Diffstat (limited to 'src/lib/extensions')
-rw-r--r-- | src/lib/extensions/discord-akairo/BushClient.ts | 23 | ||||
-rw-r--r-- | src/lib/extensions/discord.js/ExtendedGuild.ts | 1 |
2 files changed, 13 insertions, 11 deletions
diff --git a/src/lib/extensions/discord-akairo/BushClient.ts b/src/lib/extensions/discord-akairo/BushClient.ts index 855c252..9ca02a2 100644 --- a/src/lib/extensions/discord-akairo/BushClient.ts +++ b/src/lib/extensions/discord-akairo/BushClient.ts @@ -15,6 +15,7 @@ import { patch, type PatchedElements } from '@notenoughupdates/events-intercept' import * as Sentry from '@sentry/node'; import { AkairoClient, + ArgumentTypeCaster, ContextMenuCommandHandler, version as akairoVersion, type ArgumentPromptData, @@ -406,17 +407,17 @@ export class BushClient<Ready extends boolean = boolean> extends AkairoClient<Re }; this.listenerHandler.setEmitters(emitters); this.commandHandler.resolver.addTypes({ - duration, - contentWithDuration, - permission, - snowflake, - discordEmoji, - roleWithDuration, - abbreviatedNumber, - durationSeconds, - globalUser, - messageLink, - tinyColor + duration: <ArgumentTypeCaster>duration, + contentWithDuration: <ArgumentTypeCaster>contentWithDuration, + permission: <ArgumentTypeCaster>permission, + snowflake: <ArgumentTypeCaster>snowflake, + discordEmoji: <ArgumentTypeCaster>discordEmoji, + roleWithDuration: <ArgumentTypeCaster>roleWithDuration, + abbreviatedNumber: <ArgumentTypeCaster>abbreviatedNumber, + durationSeconds: <ArgumentTypeCaster>durationSeconds, + globalUser: <ArgumentTypeCaster>globalUser, + messageLink: <ArgumentTypeCaster>messageLink, + tinyColor: <ArgumentTypeCaster>tinyColor }); this.sentry.setTag('process', process.pid.toString()); diff --git a/src/lib/extensions/discord.js/ExtendedGuild.ts b/src/lib/extensions/discord.js/ExtendedGuild.ts index e55851b..3dce7ca 100644 --- a/src/lib/extensions/discord.js/ExtendedGuild.ts +++ b/src/lib/extensions/discord.js/ExtendedGuild.ts @@ -739,6 +739,7 @@ export class ExtendedGuild extends Guild { // todo: use enum for this case 24 as MessageType: { const embed = quote.embeds[0]; + // eslint-disable-next-line deprecation/deprecation assert.equal(embed.data.type, 'auto_moderation_message'); const ruleName = embed.fields!.find((f) => f.name === 'rule_name')!.value; const channelId = embed.fields!.find((f) => f.name === 'channel_id')!.value; |