mirror of
https://github.com/tomaae/homeassistant-mikrotik_router.git
synced 2025-07-10 09:24:31 +02:00
added entity update debugs #18
This commit is contained in:
parent
35936352a8
commit
1ec4e13eb8
4 changed files with 7 additions and 5 deletions
|
@ -82,9 +82,8 @@ def update_items(inst, mikrotik_controller, async_add_entities, tracked):
|
|||
|
||||
for uid in mikrotik_controller.data["interface"]:
|
||||
if mikrotik_controller.data["interface"][uid]["type"] == "ether":
|
||||
item_id = (
|
||||
f"{inst}-{mikrotik_controller.data['interface'][uid]['default-name']}"
|
||||
)
|
||||
item_id = f"{inst}-{mikrotik_controller.data['interface'][uid]['default-name']}"
|
||||
_LOGGER.debug("Updating device_tracker %s", item_id)
|
||||
if item_id in tracked:
|
||||
if tracked[item_id].enabled:
|
||||
tracked[item_id].async_schedule_update_ha_state()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue