Remove redundant device update code (#134100)

Remove redundant device update steps
pull/135635/head^2
Artur Pragacz 2025-01-20 09:37:32 +01:00 committed by GitHub
parent ff80a7c5bc
commit 877e44e3c9
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 0 additions and 10 deletions

View File

@ -958,16 +958,6 @@ class DeviceRegistry(BaseRegistry[dict[str, list[dict[str, Any]]]]):
new_values["config_entries"] = config_entries
old_values["config_entries"] = old.config_entries
for attr_name, setvalue in (
("connections", merge_connections),
("identifiers", merge_identifiers),
):
old_value = getattr(old, attr_name)
# If not undefined, check if `value` contains new items.
if setvalue is not UNDEFINED and not setvalue.issubset(old_value):
new_values[attr_name] = old_value | setvalue
old_values[attr_name] = old_value
if merge_connections is not UNDEFINED:
normalized_connections = self._validate_connections(
device_id,