fixed type=daily for provider openmeteo showing nightly icons (#3459)

in forecast when current time is "nightly"

Fixes #3458
This commit is contained in:
Karsten Hassel
2024-06-08 11:48:31 +02:00
committed by GitHub
parent cd0bc5b160
commit 4bd66cb121
2 changed files with 2 additions and 1 deletions

View File

@@ -21,6 +21,7 @@ _This release is scheduled to be released on 2024-07-01._
- [weather] Fixed precipitationProbability in forecast for provider openmeteo (#3446) - [weather] Fixed precipitationProbability in forecast for provider openmeteo (#3446)
- [weather] Fixed type=daily for provider openmeteo having no data when running after 23:00 (#3449) - [weather] Fixed type=daily for provider openmeteo having no data when running after 23:00 (#3449)
- [weather] Fixed type=daily for provider openmeteo showing nightly icons in forecast when current time is "nightly" (#3458)
## [2.27.0] - 2024-04-01 ## [2.27.0] - 2024-04-01

View File

@@ -401,7 +401,7 @@ WeatherProvider.register("openmeteo", {
currentWeather.temperature = parseFloat((weather.apparent_temperature_max + weather.apparent_temperature_min) / 2); currentWeather.temperature = parseFloat((weather.apparent_temperature_max + weather.apparent_temperature_min) / 2);
currentWeather.minTemperature = parseFloat(weather.apparent_temperature_min); currentWeather.minTemperature = parseFloat(weather.apparent_temperature_min);
currentWeather.maxTemperature = parseFloat(weather.apparent_temperature_max); currentWeather.maxTemperature = parseFloat(weather.apparent_temperature_max);
currentWeather.weatherType = this.convertWeatherType(weather.weathercode, currentWeather.isDayTime()); currentWeather.weatherType = this.convertWeatherType(weather.weathercode, true);
currentWeather.rain = parseFloat(weather.rain_sum); currentWeather.rain = parseFloat(weather.rain_sum);
currentWeather.snow = parseFloat(weather.snowfall_sum * 10); currentWeather.snow = parseFloat(weather.snowfall_sum * 10);
currentWeather.precipitationAmount = parseFloat(weather.precipitation_sum); currentWeather.precipitationAmount = parseFloat(weather.precipitation_sum);