mirror of
https://github.com/home-assistant/core.git
synced 2025-07-09 22:37:11 +00:00
Improve omnilogic
generic typing (#84686)
This commit is contained in:
parent
5e04a87cc6
commit
059ecd10a2
@ -20,7 +20,7 @@ from .const import ALL_ITEM_KINDS, DOMAIN
|
||||
_LOGGER = logging.getLogger(__name__)
|
||||
|
||||
|
||||
class OmniLogicUpdateCoordinator(DataUpdateCoordinator):
|
||||
class OmniLogicUpdateCoordinator(DataUpdateCoordinator[dict[tuple, dict[str, Any]]]):
|
||||
"""Class to manage fetching update data from single endpoint."""
|
||||
|
||||
def __init__(
|
||||
|
@ -23,7 +23,9 @@ async def async_setup_entry(
|
||||
) -> None:
|
||||
"""Set up the sensor platform."""
|
||||
|
||||
coordinator = hass.data[DOMAIN][entry.entry_id][COORDINATOR]
|
||||
coordinator: OmniLogicUpdateCoordinator = hass.data[DOMAIN][entry.entry_id][
|
||||
COORDINATOR
|
||||
]
|
||||
entities = []
|
||||
|
||||
for item_id, item in coordinator.data.items():
|
||||
|
@ -23,7 +23,9 @@ async def async_setup_entry(
|
||||
) -> None:
|
||||
"""Set up the light platform."""
|
||||
|
||||
coordinator = hass.data[DOMAIN][entry.entry_id][COORDINATOR]
|
||||
coordinator: OmniLogicUpdateCoordinator = hass.data[DOMAIN][entry.entry_id][
|
||||
COORDINATOR
|
||||
]
|
||||
entities = []
|
||||
|
||||
for item_id, item in coordinator.data.items():
|
||||
|
Loading…
x
Reference in New Issue
Block a user