mirror of
https://github.com/home-assistant/core.git
synced 2025-11-09 02:49:40 +00:00
Fix Airzone sensor and binary sensor updates (#72025)
airzone: fix sensor and binary sensor updates
This regression was introduced in b9b83c05e9
along with the modifications for the strict typing.
Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
This commit is contained in:
committed by
GitHub
parent
c3d19f3827
commit
a78f183b64
@@ -119,6 +119,12 @@ class AirzoneBinarySensor(AirzoneEntity, BinarySensorEntity):
|
|||||||
|
|
||||||
entity_description: AirzoneBinarySensorEntityDescription
|
entity_description: AirzoneBinarySensorEntityDescription
|
||||||
|
|
||||||
|
@callback
|
||||||
|
def _handle_coordinator_update(self) -> None:
|
||||||
|
"""Update attributes when the coordinator updates."""
|
||||||
|
self._async_update_attrs()
|
||||||
|
super()._handle_coordinator_update()
|
||||||
|
|
||||||
@callback
|
@callback
|
||||||
def _async_update_attrs(self) -> None:
|
def _async_update_attrs(self) -> None:
|
||||||
"""Update binary sensor attributes."""
|
"""Update binary sensor attributes."""
|
||||||
|
|||||||
@@ -102,6 +102,12 @@ async def async_setup_entry(
|
|||||||
class AirzoneSensor(AirzoneEntity, SensorEntity):
|
class AirzoneSensor(AirzoneEntity, SensorEntity):
|
||||||
"""Define an Airzone sensor."""
|
"""Define an Airzone sensor."""
|
||||||
|
|
||||||
|
@callback
|
||||||
|
def _handle_coordinator_update(self) -> None:
|
||||||
|
"""Update attributes when the coordinator updates."""
|
||||||
|
self._async_update_attrs()
|
||||||
|
super()._handle_coordinator_update()
|
||||||
|
|
||||||
@callback
|
@callback
|
||||||
def _async_update_attrs(self) -> None:
|
def _async_update_attrs(self) -> None:
|
||||||
"""Update sensor attributes."""
|
"""Update sensor attributes."""
|
||||||
|
|||||||
Reference in New Issue
Block a user