From cd648c06f3ed42b40a3f8e4f7b55283240929a93 Mon Sep 17 00:00:00 2001 From: Dani Date: Tue, 28 Jun 2016 06:43:57 +0200 Subject: [PATCH] Update restart_ha_if_wemo_switch_is_not_detected.markdown (#591) --- .../restart_ha_if_wemo_switch_is_not_detected.markdown | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/source/_cookbook/restart_ha_if_wemo_switch_is_not_detected.markdown b/source/_cookbook/restart_ha_if_wemo_switch_is_not_detected.markdown index cca4f2f07d1..cdb5fd2e8f6 100644 --- a/source/_cookbook/restart_ha_if_wemo_switch_is_not_detected.markdown +++ b/source/_cookbook/restart_ha_if_wemo_switch_is_not_detected.markdown @@ -61,22 +61,22 @@ script: entity_id: switch.killhass automation: - - alias: "Restart HA if WeMo switch isn't found after 15 minutes" +- alias: "Restart HA if WeMo switch isn't found after 15 minutes" trigger: platform: state entity_id: device_tracker.wemo from: 'not_home' to: 'home' condition: - - platform: template + - condition: template value_template: {% raw %}'{% if states.switch.wemo %}false{% else %}true{% endif %}'{% endraw %} - - platform: state + - condition: state entity_id: script.restarthawemo state: 'off' action: service: homeassistant.turn_on entity_id: script.restarthawemo - - alias: 'Stop HA' +- alias: 'Stop HA' trigger: - platform: state entity_id: switch.KillHass @@ -88,7 +88,7 @@ automation: platform: template value_template: {% raw %}'{% if states.switch.wemo %}true{% else %}false{% endif %}'{% endraw %} condition: - platform: state + condition: state entity_id: script.restarthawemo state: 'on' action: