Skip to content

[weather] openmeteo hourly does not work into next day #3449

@khassel

Description

@khassel

Now with local time 0:05 everything works as expected.

With local time 23:05 the hourly weather forecast is empty.

                const hours = [];
                const now = moment();

                weathers.hourly.forEach((weather, i) => {
                        if ((hours.length === 0 && weather.time.hour() <= now.hour()) || hours.length >= this.config.maxEntries) {
                                return;
                        }

Did this ever work? The if statement is always true (when running 23:05) so nothing is added.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions