diff options
author | IRONM00N <64110067+IRONM00N@users.noreply.github.com> | 2021-08-17 13:58:51 -0400 |
---|---|---|
committer | IRONM00N <64110067+IRONM00N@users.noreply.github.com> | 2021-08-17 13:58:51 -0400 |
commit | 71b0d425927efbdb154d343f2da463e884e8a74e (patch) | |
tree | 09e9925ef3498f87c1b1e0dcab567d460caa36b2 /src/commands/utilities/viewraw.ts | |
parent | 456f06912de38cb4d9ffa231eab1319cce2d5a08 (diff) | |
download | tanzanite-71b0d425927efbdb154d343f2da463e884e8a74e.tar.gz tanzanite-71b0d425927efbdb154d343f2da463e884e8a74e.tar.bz2 tanzanite-71b0d425927efbdb154d343f2da463e884e8a74e.zip |
fix viewraw command
Diffstat (limited to 'src/commands/utilities/viewraw.ts')
-rw-r--r-- | src/commands/utilities/viewraw.ts | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/commands/utilities/viewraw.ts b/src/commands/utilities/viewraw.ts index f6be382..bc79b7a 100644 --- a/src/commands/utilities/viewraw.ts +++ b/src/commands/utilities/viewraw.ts @@ -77,6 +77,7 @@ export default class ViewRawCommand extends BushCommand { ? inspect(JSON.stringify(message.toJSON())) : inspect(message.toJSON()) || '[No Content]' : message.content || '[No Content]'; + const lang = options.json ? 'json' : options.js ? 'js' : undefined; return ( new MessageEmbed() .setFooter(message.author.tag, message.author.avatarURL({ dynamic: true }) ?? undefined) @@ -84,7 +85,7 @@ export default class ViewRawCommand extends BushCommand { // eslint-disable-next-line @typescript-eslint/prefer-nullish-coalescing .setColor(message.member?.roles?.color?.color || util.colors.default) .setTitle('Raw Message Information') - .setDescription(await util.codeblock(content, 2048, 'js')) + .setDescription(await util.codeblock(content, 2048, lang)) ); } } |