Fix forecastTime to use API metadata instead of current time

- Use metadata.forecastTime from API response instead of endTime in fetchHistoricalFrames
- Ensures forecast time displays correctly in user's browser timezone
- Fixes issue where forecast time was showing incorrect timezone
This commit is contained in:
2025-12-23 21:03:33 +10:00
parent 93c1b710b9
commit 9d4d176013
3 changed files with 3 additions and 3 deletions
@@ -1300,7 +1300,7 @@ class RadarApiService {
frames: allFrames,
lastUpdated: endTime,
observationTime: metadata.observationTime || (newestCacheFolder === null || newestCacheFolder === void 0 ? void 0 : newestCacheFolder.observationTime) || endTime,
forecastTime: endTime,
forecastTime: metadata.forecastTime || endTime,
weatherStation: metadata.weatherStation,
distance: metadata.distance,
cacheIsValid: (_a = metadata.cacheIsValid) !== null && _a !== void 0 ? _a : true,
+1 -1
View File
@@ -22,7 +22,7 @@ services:
# Application configuration
- CACHEDIRECTORY=/app/cache
- CACHERETENTIONHOURS=24
- TIMEZONE=Australia/Brisbane
- TIMEZONE=Australia/Sydney
# Debug output enabled by default for test environment
- DEBUG__ENABLED=true
- DEBUG__WAITMS=2000
+1 -1
View File
@@ -154,7 +154,7 @@ export class RadarApiService {
frames: allFrames,
lastUpdated: endTime,
observationTime: metadata.observationTime || newestCacheFolder?.observationTime || endTime,
forecastTime: endTime,
forecastTime: metadata.forecastTime || endTime,
weatherStation: metadata.weatherStation,
distance: metadata.distance,
cacheIsValid: metadata.cacheIsValid ?? true,