Skip to content

Commit 9055375

Browse files
committed
Fixed case-sensitive bug in System Health dashboard display
- Fixed System Health showing 0/8 when all services were healthy - Changed status comparison from case-sensitive to case-insensitive in Dashboard.tsx
1 parent b4d55cb commit 9055375

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

castellan-admin/src/components/Dashboard.tsx

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -800,7 +800,15 @@ export const Dashboard = React.memo(() => {
800800
) : (
801801
<Box>
802802
<Typography variant="h4" color="success.main">
803-
{systemStatus.filter(s => s.status === 'healthy').length}/{systemStatus.length}
803+
{(() => {
804+
const healthyCount = systemStatus.filter(s => s.status && s.status.toLowerCase() === 'healthy').length;
805+
console.log('🔍 System Health Debug:', {
806+
totalServices: systemStatus.length,
807+
healthyCount,
808+
statuses: systemStatus.map(s => s.status)
809+
});
810+
return `${healthyCount}/${systemStatus.length}`;
811+
})()}
804812
</Typography>
805813
<Typography variant="body2" color="text.secondary">
806814
Healthy Services

0 commit comments

Comments
 (0)