Default observer reports to active round instead of first round
All checks were successful
Build and Push Docker Image / build (push) Successful in 8m44s

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
Matt
2026-02-19 18:52:07 +01:00
parent 0ff84686f0
commit 8ae8145d86

View File

@@ -590,10 +590,11 @@ export default function ObserverReportsPage() {
}))
) || []
// Set default selected stage
// Set default selected stage — prefer the active round, fall back to first
useEffect(() => {
if (stages.length && !selectedValue) {
setSelectedValue(stages[0].id)
const active = stages.find((s) => s.status === 'ROUND_ACTIVE')
setSelectedValue(active ? active.id : stages[0].id)
}
}, [stages.length, selectedValue])