Skip to content

Commit

Permalink
Fix var.update.
Browse files Browse the repository at this point in the history
  • Loading branch information
snarky-snark committed Aug 10, 2019
1 parent e56eb76 commit abd3181
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion custom_components/var/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -212,7 +212,7 @@ async def async_setup(hass, config):

component.async_register_entity_service(
SERVICE_UPDATE, SERVICE_UPDATE_SCHEMA,
'async_update'
'async_force_update'
)

await component.async_add_entities(entities)
Expand Down Expand Up @@ -414,6 +414,9 @@ async def async_set(self,

await self.async_update_ha_state()

async def async_force_update(self):
await self.async_update_ha_state(True)

async def async_update(self):
"""Update the state and attributes from the templates."""

Expand Down

0 comments on commit abd3181

Please sign in to comment.