Explicitly pass in the config_entry in google coordinator (#137839)

explicitly pass in the config_entry in coordinator
pull/137857/head
Michael 2025-02-08 15:34:53 +01:00 committed by GitHub
parent 70d5685b72
commit 9e091f7a73
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 6 additions and 0 deletions

View File

@ -266,6 +266,7 @@ async def async_setup_entry(
if not entity_description.local_sync:
coordinator = CalendarQueryUpdateCoordinator(
hass,
config_entry,
calendar_service,
entity_description.name or entity_description.key,
calendar_id,
@ -285,6 +286,7 @@ async def async_setup_entry(
)
coordinator = CalendarSyncUpdateCoordinator(
hass,
config_entry,
sync,
entity_description.name or entity_description.key,
)

View File

@ -52,6 +52,7 @@ class CalendarSyncUpdateCoordinator(DataUpdateCoordinator[Timeline]):
def __init__(
self,
hass: HomeAssistant,
config_entry: ConfigEntry,
sync: CalendarEventSyncManager,
name: str,
) -> None:
@ -59,6 +60,7 @@ class CalendarSyncUpdateCoordinator(DataUpdateCoordinator[Timeline]):
super().__init__(
hass,
_LOGGER,
config_entry=config_entry,
name=name,
update_interval=MIN_TIME_BETWEEN_UPDATES,
)
@ -111,6 +113,7 @@ class CalendarQueryUpdateCoordinator(DataUpdateCoordinator[list[Event]]):
def __init__(
self,
hass: HomeAssistant,
config_entry: ConfigEntry,
calendar_service: GoogleCalendarService,
name: str,
calendar_id: str,
@ -120,6 +123,7 @@ class CalendarQueryUpdateCoordinator(DataUpdateCoordinator[list[Event]]):
super().__init__(
hass,
_LOGGER,
config_entry=config_entry,
name=name,
update_interval=MIN_TIME_BETWEEN_UPDATES,
)