fix invite command

This commit is contained in:
Lio Young 2021-05-06 01:20:13 +02:00
parent db49fddf9b
commit 724d1e6a1d
No known key found for this signature in database
GPG Key ID: 789795A11879E169
1 changed files with 2 additions and 1 deletions

View File

@ -2,6 +2,7 @@ import Command from '../../handler/structures/Command';
import { Context } from '../../utils/types';
import lingua from '../../utils/lingua';
import embed from '../../utils/embed';
import replace from '../../utils/replace';
export = class Invite extends Command {
constructor() {
@ -16,7 +17,7 @@ export = class Invite extends Command {
async command(ctx: Context) {
// TODO: generate custom invites for every server
// @ts-ignore
ctx.channel.send(`${lingua[ctx.settings.locale].INVITE_STRING}:\n<${ctx.config.variables.invite}>`)
ctx.channel.send(`${replace(/BOT/gi, ctx.config.variables.name, lingua[ctx.settings.locale].INVITE_STRING)}:\n<${ctx.config.variables.invite}>`)
}
}