Skip to content

fix(firebase_types): accept both dict and list shapes for sweetSpotTimes#46

Open
zenibako wants to merge 1 commit intoWoyken:mainfrom
zenibako:main
Open

fix(firebase_types): accept both dict and list shapes for sweetSpotTimes#46
zenibako wants to merge 1 commit intoWoyken:mainfrom
zenibako:main

Conversation

@zenibako
Copy link
Copy Markdown

@zenibako zenibako commented May 1, 2026

Handle Firebase dual-shape data for sweetSpotTimes (dict and list).

Dict keys are 0-based nap indices corresponding to selectedNapDay.
Dict-shaped payloads are normalized to list[Number | None] so downstream consumers like Home Assistant get a consistent array-based structure.

Meant to align with Woyken/huckleberry-homeassistant#31.

@zenibako zenibako force-pushed the main branch 2 times, most recently from 9c485f5 to a92fd51 Compare May 1, 2026 22:14
- Normalize dict-shaped sweetSpotTimes to list[Number | None]
- Dict keys are 0-based nap indices corresponding to selectedNapDay
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant