From 8403c493426134c9d4be91d1869d2caec90d4757 Mon Sep 17 00:00:00 2001 From: Dark <7890309+DarkView@users.noreply.github.com> Date: Fri, 20 Aug 2021 19:01:47 +0200 Subject: [PATCH 1/2] Check if VC actually changed --- backend/src/plugins/Logs/events/LogsVoiceChannelEvts.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/backend/src/plugins/Logs/events/LogsVoiceChannelEvts.ts b/backend/src/plugins/Logs/events/LogsVoiceChannelEvts.ts index 0abfadc8..51e349e7 100644 --- a/backend/src/plugins/Logs/events/LogsVoiceChannelEvts.ts +++ b/backend/src/plugins/Logs/events/LogsVoiceChannelEvts.ts @@ -30,6 +30,7 @@ export const LogsVoiceStateUpdateEvt = logsEvt({ channel: newChannel, }); } else if (oldChannel && newChannel) { + if (oldChannel.id === newChannel.id) return; logVoiceChannelMove(meta.pluginData, { member, oldChannel, From d9e5c31d3a2d554a0c8be64019d7a7bca79b35f9 Mon Sep 17 00:00:00 2001 From: Dark <7890309+DarkView@users.noreply.github.com> Date: Fri, 20 Aug 2021 19:05:59 +0200 Subject: [PATCH 2/2] Same fix for Spam plugin --- backend/src/plugins/Spam/events/SpamVoiceEvt.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/backend/src/plugins/Spam/events/SpamVoiceEvt.ts b/backend/src/plugins/Spam/events/SpamVoiceEvt.ts index 36aba638..558216b9 100644 --- a/backend/src/plugins/Spam/events/SpamVoiceEvt.ts +++ b/backend/src/plugins/Spam/events/SpamVoiceEvt.ts @@ -9,6 +9,7 @@ export const SpamVoiceStateUpdateEvt = spamEvt({ if (!member) return; const channel = meta.args.newState.channel; if (!channel) return; + if (channel.id === meta.args.oldState?.id) return; const config = await meta.pluginData.config.getMatchingConfig({ member, channelId: channel.id }); const maxVoiceMoves = config.max_voice_moves;