diff options
author | IRONM00N <64110067+IRONM00N@users.noreply.github.com> | 2022-05-24 18:29:57 -0400 |
---|---|---|
committer | IRONM00N <64110067+IRONM00N@users.noreply.github.com> | 2022-05-24 18:29:57 -0400 |
commit | 9f5d9da2a37ecfec412b149ec7dc385ab7b6a98c (patch) | |
tree | 4b95a06ff6991207ab8b8e93f0bca26e24a97f80 /src/commands/utilities/decode.ts | |
parent | 6b8115ab1ec94d4330019fc7a93e094d9d64c48e (diff) | |
download | tanzanite-9f5d9da2a37ecfec412b149ec7dc385ab7b6a98c.tar.gz tanzanite-9f5d9da2a37ecfec412b149ec7dc385ab7b6a98c.tar.bz2 tanzanite-9f5d9da2a37ecfec412b149ec7dc385ab7b6a98c.zip |
fix: breaking changes
Diffstat (limited to 'src/commands/utilities/decode.ts')
-rw-r--r-- | src/commands/utilities/decode.ts | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/src/commands/utilities/decode.ts b/src/commands/utilities/decode.ts index 978c1c6..729cf35 100644 --- a/src/commands/utilities/decode.ts +++ b/src/commands/utilities/decode.ts @@ -55,17 +55,19 @@ export default class DecodeCommand extends BushCommand { const encodeOrDecode = util.capitalizeFirstLetter(message?.util?.parsed?.alias ?? 'decoded'); const decodedEmbed = new EmbedBuilder() .setTitle(`${encodeOrDecode} Information`) - .addFields({ name: '📥 Input', value: await util.inspectCleanRedactCodeblock(data) }); + .addFields([{ name: '📥 Input', value: await util.inspectCleanRedactCodeblock(data) }]); try { const decoded = Buffer.from(data, from).toString(to); decodedEmbed .setColor(util.colors.success) - .addFields({ name: '📤 Output', value: await util.inspectCleanRedactCodeblock(decoded) }); + .addFields([{ name: '📤 Output', value: await util.inspectCleanRedactCodeblock(decoded) }]); } catch (error) { - decodedEmbed.setColor(util.colors.error).addFields({ - name: `📤 Error ${encodeOrDecode.slice(1)}ing`, - value: await util.inspectCleanRedactCodeblock(error?.stack ?? error) - }); + decodedEmbed.setColor(util.colors.error).addFields([ + { + name: `📤 Error ${encodeOrDecode.slice(1)}ing`, + value: await util.inspectCleanRedactCodeblock(error?.stack ?? error) + } + ]); } return await message.util.reply({ embeds: [decodedEmbed], allowedMentions: AllowedMentions.none() }); } |