mirror of
https://github.com/home-assistant/core.git
synced 2025-07-23 05:07:41 +00:00
Disable always_update in nexia coordinator (#97436)
This commit is contained in:
parent
c11222c1d0
commit
0a56361ca4
@ -3,6 +3,7 @@ from __future__ import annotations
|
||||
|
||||
from datetime import timedelta
|
||||
import logging
|
||||
from typing import Any
|
||||
|
||||
from nexia.home import NexiaHome
|
||||
|
||||
@ -14,7 +15,7 @@ _LOGGER = logging.getLogger(__name__)
|
||||
DEFAULT_UPDATE_RATE = 120
|
||||
|
||||
|
||||
class NexiaDataUpdateCoordinator(DataUpdateCoordinator[None]):
|
||||
class NexiaDataUpdateCoordinator(DataUpdateCoordinator[dict[str, Any]]):
|
||||
"""DataUpdateCoordinator for nexia homes."""
|
||||
|
||||
def __init__(
|
||||
@ -29,8 +30,9 @@ class NexiaDataUpdateCoordinator(DataUpdateCoordinator[None]):
|
||||
_LOGGER,
|
||||
name="Nexia update",
|
||||
update_interval=timedelta(seconds=DEFAULT_UPDATE_RATE),
|
||||
always_update=False,
|
||||
)
|
||||
|
||||
async def _async_update_data(self) -> None:
|
||||
async def _async_update_data(self) -> dict[str, Any]:
|
||||
"""Fetch data from API endpoint."""
|
||||
return await self.nexia_home.update()
|
||||
|
Loading…
x
Reference in New Issue
Block a user