Skip to content

Commit 808ed03

Browse files
committed
fix(frontend): ensure Findings Explorer and summaries only include failures
1 parent f9931c3 commit 808ed03

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

apps/frontend/src/app/page.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -270,19 +270,19 @@ export default function Home() {
270270
? `${report.total_duration_ms}ms`
271271
: null;
272272

273-
const byCategory = results.reduce<Record<string, number>>((acc, item) => {
273+
const byCategory = failures.reduce<Record<string, number>>((acc, item) => {
274274
const category = String(item.category ?? "Other");
275275
acc[category] = (acc[category] ?? 0) + 1;
276276
return acc;
277277
}, {});
278278

279-
const bySeverity = results.reduce<Record<string, number>>((acc, item) => {
279+
const bySeverity = failures.reduce<Record<string, number>>((acc, item) => {
280280
const severity = String(item.severity ?? "Unknown");
281281
acc[severity] = (acc[severity] ?? 0) + 1;
282282
return acc;
283283
}, {});
284284

285-
const findingsByCategory = results.reduce<Record<string, any[]>>((acc, item) => {
285+
const findingsByCategory = failures.reduce<Record<string, any[]>>((acc, item) => {
286286
const category = String(item.category ?? "Other");
287287
if (!acc[category]) acc[category] = [];
288288
acc[category].push(item);

0 commit comments

Comments
 (0)