From 0020be1dbfbfb2e3f02d3acf8c95834025f9d101 Mon Sep 17 00:00:00 2001 From: lorentz Date: Wed, 1 Apr 2026 09:46:16 -0400 Subject: [PATCH] fix: tint phishing/sextortion rows red in table, include in high-risk summary count --- app/admin/sync/mimecast/page.tsx | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/app/admin/sync/mimecast/page.tsx b/app/admin/sync/mimecast/page.tsx index 1411c9e..5fb4c8d 100644 --- a/app/admin/sync/mimecast/page.tsx +++ b/app/admin/sync/mimecast/page.tsx @@ -1271,8 +1271,8 @@ function DeliveredMailTab() { ); const statuses = [...new Set(messages.map(m => m.status).filter(Boolean))].sort(); - const highRisk = messages.filter(m => (m.spamScore ?? 0) >= 10).length; - const medRisk = messages.filter(m => (m.spamScore ?? 0) >= 5 && (m.spamScore ?? 0) < 10).length; + const highRisk = messages.filter(m => (m.spamScore ?? 0) >= 10 || detectSubjectThreat(m.subject) !== null).length; + const medRisk = messages.filter(m => (m.spamScore ?? 0) >= 5 && (m.spamScore ?? 0) < 10 && detectSubjectThreat(m.subject) === null).length; return (
@@ -1414,7 +1414,13 @@ function DeliveredMailTab() { {filtered.map((m: any) => ( - = 10 ? 'bg-red-500/5' : m.spamScore >= 5 ? 'bg-amber-500/5' : ''}`}> + = 10 || detectSubjectThreat(m.subject) !== null + ? 'bg-red-500/5' + : m.spamScore >= 5 + ? 'bg-amber-500/5' + : '' + }`}> {new Date(m.received).toLocaleString(undefined, { month: 'short', day: 'numeric', hour: '2-digit', minute: '2-digit' })}