diff options
author | IRONM00N <64110067+IRONM00N@users.noreply.github.com> | 2021-08-31 18:45:23 -0400 |
---|---|---|
committer | IRONM00N <64110067+IRONM00N@users.noreply.github.com> | 2021-08-31 18:45:23 -0400 |
commit | a47ef150fd38fff3666faccd6f976f660fdbf9f3 (patch) | |
tree | 3f73c3d03236b09bf824469791f4ef7d2016b0b7 /src/commands/leveling/level.ts | |
parent | 9aa46f79516c0c044742339c59d471b43060d84f (diff) | |
download | tanzanite-a47ef150fd38fff3666faccd6f976f660fdbf9f3.tar.gz tanzanite-a47ef150fd38fff3666faccd6f976f660fdbf9f3.tar.bz2 tanzanite-a47ef150fd38fff3666faccd6f976f660fdbf9f3.zip |
cleanup and deprecated old config commands
Diffstat (limited to 'src/commands/leveling/level.ts')
-rw-r--r-- | src/commands/leveling/level.ts | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/commands/leveling/level.ts b/src/commands/leveling/level.ts index 6640744..f22ed8d 100644 --- a/src/commands/leveling/level.ts +++ b/src/commands/leveling/level.ts @@ -126,6 +126,11 @@ export default class LevelCommand extends BushCommand { } public override async exec(message: BushMessage | BushSlashMessage, args: { user?: BushUser }): Promise<unknown> { + if (!message.guild) return await message.util.reply(`${util.emojis.error} This command can only be run in a server.`); + if (!(await message.guild.hasFeature('leveling'))) + return await message.util.reply( + `${util.emojis.error} This command can only be run in commands with the leveling feature enabled.` + ); const user = args.user ?? message.author; try { return await message.util.reply({ |