mirror of
https://github.com/home-assistant/core.git
synced 2025-07-23 13:17:32 +00:00
Remove unnecessary assignment of Template.hass from camera (#123663)
This commit is contained in:
parent
82bedb1ab5
commit
f6e82ae0ba
@ -992,7 +992,6 @@ async def async_handle_snapshot_service(
|
||||
"""Handle snapshot services calls."""
|
||||
hass = camera.hass
|
||||
filename: Template = service_call.data[ATTR_FILENAME]
|
||||
filename.hass = hass
|
||||
|
||||
snapshot_file = filename.async_render(variables={ATTR_ENTITY_ID: camera})
|
||||
|
||||
@ -1069,9 +1068,7 @@ async def async_handle_record_service(
|
||||
if not stream:
|
||||
raise HomeAssistantError(f"{camera.entity_id} does not support record service")
|
||||
|
||||
hass = camera.hass
|
||||
filename = service_call.data[CONF_FILENAME]
|
||||
filename.hass = hass
|
||||
video_path = filename.async_render(variables={ATTR_ENTITY_ID: camera})
|
||||
|
||||
await stream.async_record(
|
||||
|
Loading…
x
Reference in New Issue
Block a user