mirror of
https://github.com/home-assistant/core.git
synced 2025-11-09 10:59:40 +00:00
Fix referenced objects in script sequences (#135499)
This commit is contained in:
@@ -1589,6 +1589,9 @@ class Script:
|
||||
target, referenced, script[CONF_SEQUENCE]
|
||||
)
|
||||
|
||||
elif action == cv.SCRIPT_ACTION_SEQUENCE:
|
||||
Script._find_referenced_target(target, referenced, step[CONF_SEQUENCE])
|
||||
|
||||
@cached_property
|
||||
def referenced_devices(self) -> set[str]:
|
||||
"""Return a set of referenced devices."""
|
||||
@@ -1636,6 +1639,9 @@ class Script:
|
||||
for script in step[CONF_PARALLEL]:
|
||||
Script._find_referenced_devices(referenced, script[CONF_SEQUENCE])
|
||||
|
||||
elif action == cv.SCRIPT_ACTION_SEQUENCE:
|
||||
Script._find_referenced_devices(referenced, step[CONF_SEQUENCE])
|
||||
|
||||
@cached_property
|
||||
def referenced_entities(self) -> set[str]:
|
||||
"""Return a set of referenced entities."""
|
||||
@@ -1684,6 +1690,9 @@ class Script:
|
||||
for script in step[CONF_PARALLEL]:
|
||||
Script._find_referenced_entities(referenced, script[CONF_SEQUENCE])
|
||||
|
||||
elif action == cv.SCRIPT_ACTION_SEQUENCE:
|
||||
Script._find_referenced_entities(referenced, step[CONF_SEQUENCE])
|
||||
|
||||
def run(
|
||||
self, variables: _VarsType | None = None, context: Context | None = None
|
||||
) -> None:
|
||||
|
||||
Reference in New Issue
Block a user