From 30473f886d70b54b016feda7ceb68396301a5b32 Mon Sep 17 00:00:00 2001 From: neodk2004 Date: Mon, 5 Oct 2026 08:08:41 +0200 Subject: [PATCH] =?UTF-8?q?fix(admin):=20Protokoll=20schreibt=20=E2=80=9Es?= =?UTF-8?q?ich=20selbst=E2=80=9C=20statt=20doppeltem=20Namen?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-Authored-By: Claude Opus 5.5 --- src/app/p/[secret]/log/page.tsx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/app/p/[secret]/log/page.tsx b/src/app/p/[secret]/log/page.tsx index 0404eff..7c36c78 100644 --- a/src/app/p/[secret]/log/page.tsx +++ b/src/app/p/[secret]/log/page.tsx @@ -50,7 +50,8 @@ const CATEGORIES = Object.keys(AUDIT_CATEGORY_LABEL) as AuditCategory[]; function EntryRow({ entry }: { entry: Entry }) { const [isOpen, setIsOpen] = useState(false); - const view = formatAuditEntry(entry); + const isSelf = entry.targetType === "USER" && entry.targetId === entry.moderatorId; + const view = formatAuditEntry({ ...entry, targetLabel: isSelf ? "sich selbst" : entry.targetLabel }); const Icon = entry.isAutomatic ? Bot : CATEGORY_ICON[view.category]; const removal = isRemoval(entry.action); const actor = entry.isAutomatic ? "Automatik" : (entry.moderatorName ?? "Unbekannt");