diff --git a/frontend/hooks/useDashboardStore.tsx b/frontend/hooks/useDashboardStore.tsx index be421f17..fffbfe53 100644 --- a/frontend/hooks/useDashboardStore.tsx +++ b/frontend/hooks/useDashboardStore.tsx @@ -584,8 +584,24 @@ export function DashboardStoreProvider({ setFutureModalDate(null); if (proAccessRef.current.loading) { - await refreshProAccess(); + setLoadingState((current) => ({ ...current, cityDetail: true })); + if (!citySummariesRef.current[cityName]) { + try { + const summary = await dashboardClient.getCitySummary(cityName); + setCitySummariesByName((current) => ({ + ...current, + [cityName]: summary, + })); + } catch { + } finally { + setLoadingState((current) => ({ ...current, cityDetail: false })); + } + } else { + setLoadingState((current) => ({ ...current, cityDetail: false })); + } + return; } + const access = proAccessRef.current; if (!access.authenticated || !access.subscriptionActive) { setLoadingState((current) => ({ ...current, cityDetail: true }));