From b2a67523a1b75839e09fab5c66c1b8d443a5b394 Mon Sep 17 00:00:00 2001 From: Dragory <2606411+Dragory@users.noreply.github.com> Date: Wed, 5 Aug 2020 02:52:45 +0300 Subject: [PATCH] Add kick reason to audit log when using !kick --- backend/src/plugins/ModActions/functions/kickMember.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/backend/src/plugins/ModActions/functions/kickMember.ts b/backend/src/plugins/ModActions/functions/kickMember.ts index f40ed76b..44ec7b7d 100644 --- a/backend/src/plugins/ModActions/functions/kickMember.ts +++ b/backend/src/plugins/ModActions/functions/kickMember.ts @@ -38,7 +38,7 @@ export async function kickMember( pluginData.state.serverLogs.ignoreLog(LogType.MEMBER_KICK, member.id); ignoreEvent(pluginData, IgnoredEventType.Kick, member.id); try { - await member.kick(); + await member.kick(reason != null ? encodeURIComponent(reason) : undefined); } catch (e) { return { status: "failed",