diff options
author | IRONM00N <64110067+IRONM00N@users.noreply.github.com> | 2022-03-03 23:45:16 -0500 |
---|---|---|
committer | IRONM00N <64110067+IRONM00N@users.noreply.github.com> | 2022-03-03 23:45:16 -0500 |
commit | 3c56bbcf795725b65192409b3211d92c097f8c82 (patch) | |
tree | 472dafca0224e61aeaffcf59ea176c534b8c3930 /src/commands/utilities/decode.ts | |
parent | 2e02220de1d1de24375db11f22b4c6626c930a28 (diff) | |
download | tanzanite-3c56bbcf795725b65192409b3211d92c097f8c82.tar.gz tanzanite-3c56bbcf795725b65192409b3211d92c097f8c82.tar.bz2 tanzanite-3c56bbcf795725b65192409b3211d92c097f8c82.zip |
refactor: preemptively switch addField to addFields
Diffstat (limited to 'src/commands/utilities/decode.ts')
-rw-r--r-- | src/commands/utilities/decode.ts | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/commands/utilities/decode.ts b/src/commands/utilities/decode.ts index 00420da..1d64145 100644 --- a/src/commands/utilities/decode.ts +++ b/src/commands/utilities/decode.ts @@ -55,14 +55,14 @@ export default class DecodeCommand extends BushCommand { const encodeOrDecode = util.capitalizeFirstLetter(message?.util?.parsed?.alias ?? 'decoded'); const decodedEmbed = new Embed() .setTitle(`${encodeOrDecode} Information`) - .addField({ 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) - .addField({ name: '📤 Output', value: await util.inspectCleanRedactCodeblock(decoded) }); + .addFields({ name: '📤 Output', value: await util.inspectCleanRedactCodeblock(decoded) }); } catch (error) { - decodedEmbed.setColor(util.colors.error).addField({ + decodedEmbed.setColor(util.colors.error).addFields({ name: `📤 Error ${encodeOrDecode.slice(1)}ing`, value: await util.inspectCleanRedactCodeblock(error?.stack ?? error) }); |