Fix device config dialog when disabled (#17464)

This commit is contained in:
karwosts 2023-08-03 00:58:06 -07:00 committed by GitHub
parent f49e103f17
commit a81050182e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1295,6 +1295,11 @@ export class HaConfigDevicePage extends LitElement {
}
}
}
} else if (
updates.disabled_by !== null &&
updates.disabled_by !== "user"
) {
delete updates.disabled_by;
}
try {
await updateDeviceRegistryEntry(this.hass, this.deviceId, updates);