Jason Rumney před 2 roky
rodič
revize
be959ea94c
1 změnil soubory, kde provedl 1 přidání a 1 odebrání
  1. 1 1
      custom_components/tuya_local/__init__.py

+ 1 - 1
custom_components/tuya_local/__init__.py

@@ -356,7 +356,7 @@ async def async_migrate_entry(hass, entry: ConfigEntry):
                     if e.entity == platform and not e.name:
                     if e.entity == platform and not e.name:
                         new_id = e.unique_id(device_id)
                         new_id = e.unique_id(device_id)
                         if (new_suffix and new_id.endswith(new_suffix)) or (
                         if (new_suffix and new_id.endswith(new_suffix)) or (
-                            new_suffix is None and new_id.contains(old_suffix)
+                            new_suffix is None and new_id.contains(suffix)
                         ):
                         ):
                             _LOGGER.info(
                             _LOGGER.info(
                                 "Migrating %s unique_id %s to %s",
                                 "Migrating %s unique_id %s to %s",