Allow use of common entity update service in AirVisual (#35203)
parent
d8ebdda714
commit
953228ebd2
|
@ -331,6 +331,13 @@ class AirVisualEntity(Entity):
|
||||||
|
|
||||||
self.update_from_latest_data()
|
self.update_from_latest_data()
|
||||||
|
|
||||||
|
async def async_update(self):
|
||||||
|
"""Update the entity.
|
||||||
|
|
||||||
|
Only used by the generic entity update service.
|
||||||
|
"""
|
||||||
|
await self.coordinator.async_request_refresh()
|
||||||
|
|
||||||
@callback
|
@callback
|
||||||
def update_from_latest_data(self):
|
def update_from_latest_data(self):
|
||||||
"""Update the entity from the latest data."""
|
"""Update the entity from the latest data."""
|
||||||
|
|
Loading…
Reference in New Issue