Merge pull request #509 from edwardtfn/patch-12

Fix for slow response with "Loading..."
This commit is contained in:
Chris
2023-03-22 21:44:38 +01:00
committed by GitHub

View File

@@ -4664,7 +4664,7 @@ action:
then: then:
- variables: - variables:
### component_to_update: "{{ repeat.item.button }}" ### component_to_update: "{{ repeat.item.button }}"
current_entity_state: "{{ states[repeat.item.entity].state }}" current_entity_state: "{{ states(repeat.item.entity) }}"
# Button PIC GRAY/WHITE # Button PIC GRAY/WHITE
btn_pic: >- btn_pic: >-
{%- if current_entity_state == 'unknown' or current_entity_state == 'unavailable' -%} {{ button_off }} {%- if current_entity_state == 'unknown' or current_entity_state == 'unavailable' -%} {{ button_off }}
@@ -4915,7 +4915,7 @@ action:
then: then:
- variables: - variables:
### component_to_update: "{{ repeat.item.button }}" ### component_to_update: "{{ repeat.item.button }}"
current_entity_state: "{{ states[repeat.item.entity].state }}" current_entity_state: "{{ states(repeat.item.entity) }}"
# Button PIC GRAY/WHITE # Button PIC GRAY/WHITE
btn_pic: >- btn_pic: >-
{%- if current_entity_state == 'unknown' or current_entity_state == 'unavailable' -%} {{ button_off }} {%- if current_entity_state == 'unknown' or current_entity_state == 'unavailable' -%} {{ button_off }}
@@ -5166,7 +5166,7 @@ action:
then: then:
- variables: - variables:
### component_to_update: "{{ repeat.item.button }}" ### component_to_update: "{{ repeat.item.button }}"
current_entity_state: "{{ states[repeat.item.entity].state }}" current_entity_state: "{{ states(repeat.item.entity) }}"
# Button PIC GRAY/WHITE # Button PIC GRAY/WHITE
btn_pic: >- btn_pic: >-
{%- if current_entity_state == 'unknown' or current_entity_state == 'unavailable' -%} {{ button_off }} {%- if current_entity_state == 'unknown' or current_entity_state == 'unavailable' -%} {{ button_off }}
@@ -5417,7 +5417,7 @@ action:
then: then:
- variables: - variables:
### component_to_update: "{{ repeat.item.button }}" ### component_to_update: "{{ repeat.item.button }}"
current_entity_state: "{{ states[repeat.item.entity].state }}" current_entity_state: "{{ states(repeat.item.entity) }}"
# Button PIC GRAY/WHITE # Button PIC GRAY/WHITE
btn_pic: >- btn_pic: >-
{%- if current_entity_state == 'unknown' or current_entity_state == 'unavailable' -%} {{ button_off }} {%- if current_entity_state == 'unknown' or current_entity_state == 'unavailable' -%} {{ button_off }}