diff --git a/src/components/exec-bench-table.tsx b/src/components/exec-bench-table.tsx index ac60824f..e3d085b2 100644 --- a/src/components/exec-bench-table.tsx +++ b/src/components/exec-bench-table.tsx @@ -28,6 +28,13 @@ export function ExecBenchTable({ data: ExecLeaderboardResponse | null; }) { const [win, setWin] = useState("24h"); + const stale = useMemo( + () => + data?.updatedAt + ? Date.now() - new Date(data.updatedAt).getTime() > 3 * 60 * 60 * 1000 + : false, + [data?.updatedAt] + ); if (!data) { return ( @@ -42,14 +49,6 @@ export function ExecBenchTable({ (b.windows[win]?.txCount ?? 0) - (a.windows[win]?.txCount ?? 0), ); - const stale = useMemo( - () => - data.updatedAt - ? Date.now() - new Date(data.updatedAt).getTime() > 3 * 60 * 60 * 1000 - : false, - [data.updatedAt] - ); - return (