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/moulberry-bush/report.ts | |
parent | 6b8115ab1ec94d4330019fc7a93e094d9d64c48e (diff) | |
download | tanzanite-9f5d9da2a37ecfec412b149ec7dc385ab7b6a98c.tar.gz tanzanite-9f5d9da2a37ecfec412b149ec7dc385ab7b6a98c.tar.bz2 tanzanite-9f5d9da2a37ecfec412b149ec7dc385ab7b6a98c.zip |
fix: breaking changes
Diffstat (limited to 'src/commands/moulberry-bush/report.ts')
-rw-r--r-- | src/commands/moulberry-bush/report.ts | 42 |
1 files changed, 22 insertions, 20 deletions
diff --git a/src/commands/moulberry-bush/report.ts b/src/commands/moulberry-bush/report.ts index 4d57fcd..f8f6371 100644 --- a/src/commands/moulberry-bush/report.ts +++ b/src/commands/moulberry-bush/report.ts @@ -71,32 +71,34 @@ export default class ReportCommand extends BushCommand { .setTitle('New Report') .setColor(util.colors.red) .setDescription(evidence) - .addFields({ - name: 'Reporter', - value: [ - `**Name:**${message.author.tag} <@${message.author.id}>`, - `**Joined:** $${util.timestampAndDelta(message.member!.joinedAt!)}`, - `**Created:** ${util.timestampAndDelta(message.author.createdAt)}`, - `**Sent From**: <#${message.channel.id}> [Jump to context](${message.url})` - ].join('\n'), - inline: true - }) - .addFields({ - name: 'Reported User', - value: [ - `**Name:**${member.user.tag} <@${member.user.id}>`, - `**Joined:** $${util.timestampAndDelta(member.joinedAt!)}`, - `**Created:** ${util.timestampAndDelta(member.user.createdAt)}` - ].join('\n'), - inline: true - }); + .addFields([ + { + name: 'Reporter', + value: [ + `**Name:**${message.author.tag} <@${message.author.id}>`, + `**Joined:** $${util.timestampAndDelta(message.member!.joinedAt!)}`, + `**Created:** ${util.timestampAndDelta(message.author.createdAt)}`, + `**Sent From**: <#${message.channel.id}> [Jump to context](${message.url})` + ].join('\n'), + inline: true + }, + { + name: 'Reported User', + value: [ + `**Name:**${member.user.tag} <@${member.user.id}>`, + `**Joined:** $${util.timestampAndDelta(member.joinedAt!)}`, + `**Created:** ${util.timestampAndDelta(member.user.createdAt)}` + ].join('\n'), + inline: true + } + ]); if (message.attachments.size > 0) { const fileName = message.attachments.first()!.name!.toLowerCase(); if (fileName.endsWith('.png') || fileName.endsWith('.jpg') || fileName.endsWith('.gif') || fileName.endsWith('.webp')) { reportEmbed.setImage(message.attachments.first()!.url); } else { - reportEmbed.addFields({ name: 'Attachment', value: message.attachments.first()!.url }); + reportEmbed.addFields([{ name: 'Attachment', value: message.attachments.first()!.url }]); } } await reportChannel.send({ embeds: [reportEmbed] }).then(async (ReportMessage) => { |