mirror of
https://github.com/home-assistant/core.git
synced 2025-07-10 23:07:09 +00:00
Fix google calendar disabled entity handling (#76699)
Fix google calendar disable entity handling
This commit is contained in:
parent
bcc0a92e2b
commit
b969ed00b9
@ -192,7 +192,6 @@ async def async_setup_entry(
|
|||||||
calendar_id,
|
calendar_id,
|
||||||
data.get(CONF_SEARCH),
|
data.get(CONF_SEARCH),
|
||||||
)
|
)
|
||||||
await coordinator.async_config_entry_first_refresh()
|
|
||||||
entities.append(
|
entities.append(
|
||||||
GoogleCalendarEntity(
|
GoogleCalendarEntity(
|
||||||
coordinator,
|
coordinator,
|
||||||
@ -342,6 +341,9 @@ class GoogleCalendarEntity(CoordinatorEntity, CalendarEntity):
|
|||||||
async def async_added_to_hass(self) -> None:
|
async def async_added_to_hass(self) -> None:
|
||||||
"""When entity is added to hass."""
|
"""When entity is added to hass."""
|
||||||
await super().async_added_to_hass()
|
await super().async_added_to_hass()
|
||||||
|
# We do not ask for an update with async_add_entities()
|
||||||
|
# because it will update disabled entities
|
||||||
|
await self.coordinator.async_request_refresh()
|
||||||
self._apply_coordinator_update()
|
self._apply_coordinator_update()
|
||||||
|
|
||||||
async def async_get_events(
|
async def async_get_events(
|
||||||
|
Loading…
x
Reference in New Issue
Block a user