Fix jwt-token

This commit is contained in:
2025-08-19 04:32:32 +02:00
parent da6e8bbaac
commit 5142049de5

View File

@@ -209,7 +209,6 @@ const MapView = () => {
const centerLat = (minLat + maxLat) / 2;
const centerLon = (minLon + maxLon) / 2;
setMapCenter([centerLat, centerLon]);
setIsInitialLoad(false); // Mark that initial load is complete
// Disable bounds fitting after a short delay to allow initial fit
setTimeout(() => {
@@ -217,6 +216,11 @@ const MapView = () => {
}, 1000);
}
}
// Always mark initial load as complete after first fetch, regardless of device data
if (isInitialLoad) {
setIsInitialLoad(false);
}
} catch (error) {
console.error('Error fetching devices:', error);
} finally {