Explorar el Código

Fix issue with GPCV lock support.

An typo in use of the constant caused the lock to fail to initialise if it reached the GPCV condition. Since that was last in the list, it went undetected.
Jason Rumney hace 6 años
padre
commit
ef71aedfd6
Se han modificado 1 ficheros con 1 adiciones y 1 borrados
  1. 1 1
      custom_components/goldair_climate/lock.py

+ 1 - 1
custom_components/goldair_climate/lock.py

@@ -27,7 +27,7 @@ async def async_setup_platform(hass, config, async_add_entities, discovery_info=
         data[CONF_CHILD_LOCK] = GoldairDehumidifierChildLock(device)
     elif discovery_info[CONF_TYPE] == CONF_TYPE_FAN:
         raise ValueError("Goldair fans do not support child lock.")
-    elif discovery_info[CONF_TYPE] == CONF_GPCV_HEATER:
+    elif discovery_info[CONF_TYPE] == CONF_TYPE_GPCV_HEATER:
         data[CONF_CHILD_LOCK] = GoldairGPCVHeaterChildLock(device)
 
     if CONF_CHILD_LOCK in data: