From 188f5de5ae8343f3a091347a89ec6504444d75f0 Mon Sep 17 00:00:00 2001
From: Aaron Bach <bachya1208@gmail.com>
Date: Tue, 11 Sep 2018 17:13:16 -0600
Subject: [PATCH] Fixes an OpenUV bug with the scan interval (#16570)

---
 homeassistant/components/openuv/__init__.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/homeassistant/components/openuv/__init__.py b/homeassistant/components/openuv/__init__.py
index bfd90b4a574..35ab16b4d1f 100644
--- a/homeassistant/components/openuv/__init__.py
+++ b/homeassistant/components/openuv/__init__.py
@@ -179,7 +179,7 @@ async def async_setup_entry(hass, config_entry):
     hass.data[DOMAIN][DATA_OPENUV_LISTENER][
         config_entry.entry_id] = async_track_time_interval(
             hass, refresh_sensors,
-            hass.data[DOMAIN][CONF_SCAN_INTERVAL])
+            hass.data[DOMAIN].get(CONF_SCAN_INTERVAL, DEFAULT_SCAN_INTERVAL))
 
     return True
 
-- 
GitLab