extended forecast silent refresh

This commit is contained in:
Matt Walsh
2025-04-02 20:58:53 -05:00
parent 0baa31a92c
commit f7a15a93c6
4 changed files with 26 additions and 26 deletions

View File

@@ -24,6 +24,8 @@ class CurrentWeather extends WeatherDisplay {
async getData(weatherParameters, refresh) {
// always load the data for use in the lower scroll
const superResult = super.getData(weatherParameters, refresh);
// note: current weather does not use old data on a silent refresh
// this is deliberate because it can pull data from more than one station in sequence
// filter for 4-letter observation stations, only those contain sky conditions and thus an icon
const filteredStations = this.weatherParameters.stations.filter((station) => station?.properties?.stationIdentifier?.length === 4 && !skipStations.includes(station.properties.stationIdentifier.slice(0, 1)));