diff --git a/homeassistant/components/linear_garage_door/__init__.py b/homeassistant/components/linear_garage_door/__init__.py index e4aa30c98df..5e524fbb512 100644 --- a/homeassistant/components/linear_garage_door/__init__.py +++ b/homeassistant/components/linear_garage_door/__init__.py @@ -31,7 +31,7 @@ async def async_setup_entry(hass: HomeAssistant, entry: ConfigEntry) -> bool: }, ) - coordinator = LinearUpdateCoordinator(hass) + coordinator = LinearUpdateCoordinator(hass, entry) await coordinator.async_config_entry_first_refresh() diff --git a/homeassistant/components/linear_garage_door/coordinator.py b/homeassistant/components/linear_garage_door/coordinator.py index 38b1306ec38..b55affe92e7 100644 --- a/homeassistant/components/linear_garage_door/coordinator.py +++ b/homeassistant/components/linear_garage_door/coordinator.py @@ -34,15 +34,16 @@ class LinearUpdateCoordinator(DataUpdateCoordinator[dict[str, LinearDevice]]): _devices: list[dict[str, Any]] | None = None config_entry: ConfigEntry - def __init__(self, hass: HomeAssistant) -> None: + def __init__(self, hass: HomeAssistant, config_entry: ConfigEntry) -> None: """Initialize DataUpdateCoordinator for Linear.""" super().__init__( hass, _LOGGER, + config_entry=config_entry, name="Linear Garage Door", update_interval=timedelta(seconds=60), ) - self.site_id = self.config_entry.data["site_id"] + self.site_id = config_entry.data["site_id"] async def _async_update_data(self) -> dict[str, LinearDevice]: """Get the data for Linear."""