I hereby decree that this document shall no longer contain the substring " == ", and hereafter shall be referred to as " === ". This amendment shall take effect immediately.
Signed-off-by: pineafan <pineapplefanyt@gmail.com>
diff --git a/src/events/guildMemberUpdate.ts b/src/events/guildMemberUpdate.ts
index e68aee4..d555647 100644
--- a/src/events/guildMemberUpdate.ts
+++ b/src/events/guildMemberUpdate.ts
@@ -4,9 +4,9 @@
try {
const { log, NucleusColors, entry, renderUser, renderDelta, getAuditLog } = after.client.logger
let auditLog = await getAuditLog(after.guild, 'MEMBER_UPDATE');
- let audit = auditLog.entries.filter(entry => entry.target.id == after.id).first();
- if (audit.executor.id == client.user.id) return;
- if (before.nickname != after.nickname) {
+ let audit = auditLog.entries.filter(entry => entry.target.id === after.id).first();
+ if (audit.executor.id === client.user.id) return;
+ if (before.nickname !== after.nickname) {
try { await client.database.history.create(
"nickname", after.guild.id, after.user, audit.executor,
null, before.nickname || before.user.username, after.nickname || after.user.username) } catch {}