Apply late review of tankerkoenig (#114582)

remove config entry from device, not device itself
This commit is contained in:
Michael 2024-04-01 19:36:57 +02:00 committed by GitHub
parent 94060b1566
commit 886f03dd71
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -101,7 +101,9 @@ class TankerkoenigDataUpdateCoordinator(DataUpdateCoordinator):
for station_id in self._selected_stations
):
_LOGGER.debug("Removing obsolete device entry %s", device.name)
device_reg.async_remove_device(device.id)
device_reg.async_update_device(
device.id, remove_config_entry_id=self.config_entry.entry_id
)
if len(self.stations) > 10:
_LOGGER.warning(