mirror of
https://github.com/home-assistant/core.git
synced 2025-07-19 11:17:21 +00:00
Allow use of common entity update service in AirVisual (#35203)
This commit is contained in:
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…
x
Reference in New Issue
Block a user