From ad5273ded16d66be316339a9c15bde5b21bab076 Mon Sep 17 00:00:00 2001 From: "J. Nick Koston" Date: Thu, 8 Oct 2020 02:20:39 -0500 Subject: [PATCH] Update config to use async_add_executor_job (#41452) --- homeassistant/components/config/__init__.py | 2 +- homeassistant/components/config/zwave.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/homeassistant/components/config/__init__.py b/homeassistant/components/config/__init__.py index 54482ffa34a..1098594a04c 100644 --- a/homeassistant/components/config/__init__.py +++ b/homeassistant/components/config/__init__.py @@ -189,7 +189,7 @@ class BaseEditConfigView(HomeAssistantView): async def read_config(self, hass): """Read the config.""" - current = await hass.async_add_job(_read, hass.config.path(self.path)) + current = await hass.async_add_executor_job(_read, hass.config.path(self.path)) if not current: current = self._empty_config() return current diff --git a/homeassistant/components/config/zwave.py b/homeassistant/components/config/zwave.py index 7a99d29c774..ca1a99c6bb7 100644 --- a/homeassistant/components/config/zwave.py +++ b/homeassistant/components/config/zwave.py @@ -54,7 +54,7 @@ class ZWaveLogView(HomeAssistantView): return Response(text="Invalid datetime", status=HTTP_BAD_REQUEST) hass = request.app["hass"] - response = await hass.async_add_job(self._get_log, hass, lines) + response = await hass.async_add_executor_job(self._get_log, hass, lines) return Response(text="\n".join(response))