Bug fixes and ~~performance~~ typing improvements
diff --git a/src/events/stickerDelete.ts b/src/events/stickerDelete.ts
index f390b5c..7ac17ce 100644
--- a/src/events/stickerDelete.ts
+++ b/src/events/stickerDelete.ts
@@ -1,12 +1,9 @@
export const event = "stickerDelete";
export async function callback(client, emoji) {
- const { getAuditLog, log, NucleusColors, entry, renderUser, renderDelta } =
- emoji.client.logger;
+ const { getAuditLog, log, NucleusColors, entry, renderUser, renderDelta } = emoji.client.logger;
const auditLog = await getAuditLog(emoji.guild, "STICKER_DELETE");
- const audit = auditLog.entries
- .filter((entry) => entry.target.id === emoji.id)
- .first();
+ const audit = auditLog.entries.filter((entry) => entry.target.id === emoji.id).first();
if (audit.executor.id === client.user.id) return;
const data = {
meta: {
@@ -21,14 +18,8 @@
stickerId: entry(emoji.id, `\`${emoji.id}\``),
sticker: entry(emoji.name, `\`${emoji.name}\``),
deletedBy: entry(audit.executor.id, renderUser(audit.executor)),
- created: entry(
- emoji.createdTimestamp,
- renderDelta(emoji.createdTimestamp)
- ),
- deleted: entry(
- audit.createdTimestamp,
- renderDelta(audit.createdTimestamp)
- )
+ created: entry(emoji.createdTimestamp, renderDelta(emoji.createdTimestamp)),
+ deleted: entry(audit.createdTimestamp, renderDelta(audit.createdTimestamp))
},
hidden: {
guild: emoji.guild.id