ソースを参照

config_flow: allow "exists" attribute to be missing when reading

Issue #1054
Jason Rumney 1 年間 前
コミット
4bb067c91b
1 ファイル変更1 行追加1 行削除
  1. 1 1
      custom_components/tuya_local/config_flow.py

+ 1 - 1
custom_components/tuya_local/config_flow.py

@@ -324,7 +324,7 @@ class ConfigFlowHandler(config_entries.ConfigFlow, domain=DOMAIN):
         device_list = []
         for key in self.__cloud_devices.keys():
             device_entry = self.__cloud_devices[key]
-            if device_entry["exists"]:
+            if device_entry.get("exists"):
                 continue
             if device_entry[CONF_LOCAL_KEY] != "":
                 if device_entry["online"]: