fixed type=daily for provider openmeteo having no data … (#3451)

… when running after 23:00

Fixes #3449
This commit is contained in:
Karsten Hassel 2024-05-20 09:36:03 +02:00 committed by GitHub
parent d1c17e7fc0
commit cd0bc5b160
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 2 additions and 1 deletions

View File

@ -20,6 +20,7 @@ _This release is scheduled to be released on 2024-07-01._
### Fixed
- [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)
## [2.27.0] - 2024-04-01

View File

@ -420,7 +420,7 @@ WeatherProvider.register("openmeteo", {
const now = moment();
weathers.hourly.forEach((weather, i) => {
if ((hours.length === 0 && weather.time.hour() <= now.hour()) || hours.length >= this.config.maxEntries) {
if ((hours.length === 0 && weather.time <= now) || hours.length >= this.config.maxEntries) {
return;
}