Skip to content

Commit 4ef0d0f

Browse files
authored
Merge pull request #1366 from custom-components/fix_cleanup
fix cleanup service
2 parents a5a8e53 + c7198fd commit 4ef0d0f

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

custom_components/ble_monitor/__init__.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -412,7 +412,7 @@ async def async_cleanup_entries_service(hass: HomeAssistant, service_data):
412412

413413
# Remove devices that don't belong to any entity
414414
for device_id in devices_to_be_removed:
415-
if len(ent_registry.async_entries_for_device(ent_registry, device_id)) == 0:
415+
if len(entity_registry.async_entries_for_device(ent_registry, device_id)) == 0:
416416
dev_registry.async_remove_device(device_id)
417417
_LOGGER.debug("device %s will be deleted", device_id)
418418

requirements_test.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
pytest-homeassistant-custom-component==0.13.119
1+
pytest-homeassistant-custom-component==0.13.133
22

33
# BLE montitor requirements
44
pycryptodomex==3.19.1

0 commit comments

Comments
 (0)