aboutsummaryrefslogtreecommitdiff
path: root/src/commands
diff options
context:
space:
mode:
authorIRONM00N <64110067+IRONM00N@users.noreply.github.com>2022-08-05 20:10:42 -0400
committerIRONM00N <64110067+IRONM00N@users.noreply.github.com>2022-08-05 20:10:42 -0400
commite4206aaa9211e792660b4015551519d633409355 (patch)
treef79cc2dd3138492b944da599e7c1b6aa09fc1d1c /src/commands
parent5e88fbf7c78a5d81f2cb7f2265b16cbb7713d07c (diff)
downloadtanzanite-e4206aaa9211e792660b4015551519d633409355.tar.gz
tanzanite-e4206aaa9211e792660b4015551519d633409355.tar.bz2
tanzanite-e4206aaa9211e792660b4015551519d633409355.zip
random stuff
Diffstat (limited to 'src/commands')
-rw-r--r--src/commands/info/inviteInfo.ts6
-rw-r--r--src/commands/utilities/highlight-!.ts5
2 files changed, 4 insertions, 7 deletions
diff --git a/src/commands/info/inviteInfo.ts b/src/commands/info/inviteInfo.ts
index bfe7eae..5df86ad 100644
--- a/src/commands/info/inviteInfo.ts
+++ b/src/commands/info/inviteInfo.ts
@@ -28,15 +28,15 @@ export default class InviteInfoCommand extends BushCommand {
public override async exec(message: CommandMessage | SlashMessage, args: { invite: ArgType<'invite' | 'string'> }) {
const invite = message.util.isSlashMessage(message)
? ((await Arg.cast('invite', message, args.invite as string)) as ArgType<'invite'>)
- : args.invite;
+ : (args.invite as Invite);
- const inviteInfoEmbed = new EmbedBuilder().setTitle(`Invite to ${invite.guild.name}`).setColor(colors.default);
+ const inviteInfoEmbed = new EmbedBuilder().setTitle(`Invite to ${invite.guild!.name}`).setColor(colors.default);
this.generateAboutField(inviteInfoEmbed, invite);
}
private generateAboutField(embed: EmbedBuilder, invite: Invite) {
- const about = [`**code:** ${invite.code}`, `**channel:** ${}`];
+ const about = [`**code:** ${invite.code}`, `**channel:** ${invite.channel!.name}`];
embed.addFields({ name: 'ยป About', value: about.join('\n') });
}
diff --git a/src/commands/utilities/highlight-!.ts b/src/commands/utilities/highlight-!.ts
index b93f59a..f2ee259 100644
--- a/src/commands/utilities/highlight-!.ts
+++ b/src/commands/utilities/highlight-!.ts
@@ -186,10 +186,7 @@ export default class HighlightCommand extends BushCommand {
throw new Error('This command is not meant to be executed directly.');
}
- public override async execSlash(
- message: SlashMessage,
- args: { subcommand: keyof typeof highlightSubcommands; subcommandGroup?: string }
- ) {
+ public override async execSlash(message: SlashMessage, args: { subcommand: string; subcommandGroup?: string }) {
// manual `Flag.continue`
const subcommand = this.handler.modules.get(`highlight-${args.subcommandGroup ?? args.subcommand}`)!;
return subcommand.exec(message, args);