mirror of
https://github.com/home-assistant/core.git
synced 2025-07-17 10:17:09 +00:00
Clean up early assignment in script response (#131691)
This commit is contained in:
parent
96eae1221c
commit
56b4733e4a
@ -473,11 +473,13 @@ class _ScriptRun:
|
|||||||
script_execution_set("aborted")
|
script_execution_set("aborted")
|
||||||
except _StopScript as err:
|
except _StopScript as err:
|
||||||
script_execution_set("finished", err.response)
|
script_execution_set("finished", err.response)
|
||||||
response = err.response
|
|
||||||
|
|
||||||
# Let the _StopScript bubble up if this is a sub-script
|
# Let the _StopScript bubble up if this is a sub-script
|
||||||
if not self._script.top_level:
|
if not self._script.top_level:
|
||||||
raise
|
raise
|
||||||
|
|
||||||
|
response = err.response
|
||||||
|
|
||||||
except Exception:
|
except Exception:
|
||||||
script_execution_set("error")
|
script_execution_set("error")
|
||||||
raise
|
raise
|
||||||
|
Loading…
x
Reference in New Issue
Block a user