Răsfoiți Sursa

Build list of possible types from legacy_type, not config itself.

Jason Rumney 4 ani în urmă
părinte
comite
b9ff2339d5
1 a modificat fișierele cu 1 adăugiri și 1 ștergeri
  1. 1 1
      custom_components/tuya_local/config_flow.py

+ 1 - 1
custom_components/tuya_local/config_flow.py

@@ -45,7 +45,7 @@ class ConfigFlowHandler(config_entries.ConfigFlow, domain=DOMAIN):
 
 
         types = []
         types = []
         async for type in self.device.async_possible_types():
         async for type in self.device.async_possible_types():
-            types.append(type)
+            types.append(type.legacy_type)
         if types:
         if types:
             return self.async_show_form(
             return self.async_show_form(
                 step_id="type",
                 step_id="type",