Explicitly pass in the config_entry in arve coordinator init (#137712)

explicitly pass in the config_entry in arve coordinator init
This commit is contained in:
Michael 2025-02-07 23:20:08 +01:00 committed by GitHub
parent 292409f1d5
commit 2d9db62828
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 3 additions and 2 deletions

View File

@ -13,7 +13,7 @@ PLATFORMS: list[Platform] = [Platform.SENSOR]
async def async_setup_entry(hass: HomeAssistant, entry: ArveConfigEntry) -> bool:
"""Set up Arve from a config entry."""
coordinator = ArveCoordinator(hass)
coordinator = ArveCoordinator(hass, entry)
await coordinator.async_config_entry_first_refresh()

View File

@ -30,11 +30,12 @@ class ArveCoordinator(DataUpdateCoordinator[ArveSensProData]):
config_entry: ArveConfigEntry
devices: ArveDevices
def __init__(self, hass: HomeAssistant) -> None:
def __init__(self, hass: HomeAssistant, config_entry: ArveConfigEntry) -> None:
"""Initialize Arve coordinator."""
super().__init__(
hass,
LOGGER,
config_entry=config_entry,
name=DOMAIN,
update_interval=timedelta(seconds=60),
)