From 34231383ec5a12734d57f430873ddce4b3f8365f Mon Sep 17 00:00:00 2001 From: Evan Bruhn Date: Tue, 25 Jun 2019 02:36:39 +1000 Subject: [PATCH] Save cached logi_circle tokens in config folder (#24726) Instead of the working directory, which it's doing currently. Matches pattern observed on Abode, Ring, Skybell integrations. --- homeassistant/components/logi_circle/__init__.py | 2 +- homeassistant/components/logi_circle/config_flow.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/homeassistant/components/logi_circle/__init__.py b/homeassistant/components/logi_circle/__init__.py index 4e5ad0c5aeb..2f34366aafa 100644 --- a/homeassistant/components/logi_circle/__init__.py +++ b/homeassistant/components/logi_circle/__init__.py @@ -105,7 +105,7 @@ async def async_setup_entry(hass, entry): client_secret=entry.data[CONF_CLIENT_SECRET], api_key=entry.data[CONF_API_KEY], redirect_uri=entry.data[CONF_REDIRECT_URI], - cache_file=DEFAULT_CACHEDB + cache_file=hass.config.path(DEFAULT_CACHEDB) ) if not logi_circle.authorized: diff --git a/homeassistant/components/logi_circle/config_flow.py b/homeassistant/components/logi_circle/config_flow.py index 728ca27ba51..7f1f085bbac 100644 --- a/homeassistant/components/logi_circle/config_flow.py +++ b/homeassistant/components/logi_circle/config_flow.py @@ -157,7 +157,7 @@ class LogiCircleFlowHandler(config_entries.ConfigFlow): client_secret=client_secret, api_key=api_key, redirect_uri=redirect_uri, - cache_file=DEFAULT_CACHEDB) + cache_file=self.hass.config.path(DEFAULT_CACHEDB)) try: with async_timeout.timeout(_TIMEOUT):