Adjust homekit to not access DeviceEntry.config_entries (#181744)

This commit is contained in:
Erik Montnemery
2026-09-09 14:05:29 +02:00
committed by GitHub
parent 95b1211180
commit 2caca4843c
+4 -4
View File
@@ -1259,10 +1259,10 @@ class HomeKit:
config[ATTR_SW_VERSION] = device_entry.sw_version
if device_entry.hw_version:
config[ATTR_HW_VERSION] = device_entry.hw_version
if device_entry.config_entries:
first_entry = list(device_entry.config_entries)[0]
if entry := self.hass.config_entries.async_get_entry(first_entry):
config[ATTR_INTEGRATION] = entry.domain
if entry := self.hass.config_entries.async_get_entry(
device_entry.config_entry_id
):
config[ATTR_INTEGRATION] = entry.domain
class HomeKitPairingQRView(HomeAssistantView):