From ec7c5a68021452bc466585afa9ad2e4a6dc12703 Mon Sep 17 00:00:00 2001 From: kyle Date: Tue, 3 Feb 2026 21:04:48 +0100 Subject: [PATCH] fix: auto-refresh enrolled devices list every 30 seconds The useGpsDevices query was missing refetchInterval, so the Last Active timestamp on the Enrolled Devices page only updated on initial page load. Co-Authored-By: Claude Opus 4.5 --- frontend/src/hooks/useGps.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/frontend/src/hooks/useGps.ts b/frontend/src/hooks/useGps.ts index 947b7ed..0ddc8ef 100644 --- a/frontend/src/hooks/useGps.ts +++ b/frontend/src/hooks/useGps.ts @@ -74,6 +74,7 @@ export function useGpsDevices() { const { data } = await api.get('/gps/devices'); return data; }, + refetchInterval: 30000, // Refresh every 30 seconds to update lastActive }); }