Selaa lähdekoodia

Update __init__.py

Vassilis Panos 7 vuotta sitten
vanhempi
sitoutus
ad90a812fb
1 muutettua tiedostoa jossa 4 lisäystä ja 0 poistoa
  1. 4 0
      smartir/__init__.py

+ 4 - 0
smartir/__init__.py

@@ -40,6 +40,10 @@ CONFIG_SCHEMA = vol.Schema({
 async def async_setup(hass, config):
     """Set up the SmartIR component."""
     conf = config.get(DOMAIN)
+
+    if conf is None:
+        return True
+
     check_updates = conf[CONF_CHECK_UPDATES]
     update_branch = conf[CONF_UPDATE_BRANCH]