mirror of
https://github.com/home-assistant/core.git
synced 2025-06-18 20:17:07 +00:00
Make group _update_at_start a callback (#102286)
This commit is contained in:
parent
870e38e8ba
commit
393544b3e7
@ -526,12 +526,13 @@ class GroupEntity(Entity):
|
|||||||
self.hass, self._entity_ids, async_state_changed_listener
|
self.hass, self._entity_ids, async_state_changed_listener
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
|
self.async_on_remove(start.async_at_start(self.hass, self._update_at_start))
|
||||||
|
|
||||||
async def _update_at_start(_: HomeAssistant) -> None:
|
@callback
|
||||||
self.async_update_group_state()
|
def _update_at_start(self, _: HomeAssistant) -> None:
|
||||||
self.async_write_ha_state()
|
"""Update the group state at start."""
|
||||||
|
self.async_update_group_state()
|
||||||
self.async_on_remove(start.async_at_start(self.hass, _update_at_start))
|
self.async_write_ha_state()
|
||||||
|
|
||||||
@callback
|
@callback
|
||||||
def async_defer_or_update_ha_state(self) -> None:
|
def async_defer_or_update_ha_state(self) -> None:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user