mirror of
https://github.com/home-assistant/core.git
synced 2025-07-16 17:57:11 +00:00
Remove unnecessary force_refresh=True, clarify system behavior (#26543)
* Remove unnecessary force_refresh=True, clarify system behavior * Fix lint.
This commit is contained in:
parent
9df5c0ab86
commit
adf6852acc
@ -145,7 +145,14 @@ def refresh_system(func):
|
|||||||
|
|
||||||
|
|
||||||
class AqualinkEntity(Entity):
|
class AqualinkEntity(Entity):
|
||||||
"""Abstract class for all Aqualink platforms."""
|
"""Abstract class for all Aqualink platforms.
|
||||||
|
|
||||||
|
Entity state is updated via the interval timer within the integration.
|
||||||
|
Any entity state change via the iaqualink library triggers an internal
|
||||||
|
state refresh which is then propagated to all the entities in the system
|
||||||
|
via the refresh_system decorator above to the _update_callback in this
|
||||||
|
class.
|
||||||
|
"""
|
||||||
|
|
||||||
async def async_added_to_hass(self) -> None:
|
async def async_added_to_hass(self) -> None:
|
||||||
"""Set up a listener when this entity is added to HA."""
|
"""Set up a listener when this entity is added to HA."""
|
||||||
@ -153,7 +160,7 @@ class AqualinkEntity(Entity):
|
|||||||
|
|
||||||
@callback
|
@callback
|
||||||
def _update_callback(self) -> None:
|
def _update_callback(self) -> None:
|
||||||
self.async_schedule_update_ha_state(force_refresh=True)
|
self.async_schedule_update_ha_state()
|
||||||
|
|
||||||
@property
|
@property
|
||||||
def should_poll(self) -> bool:
|
def should_poll(self) -> bool:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user