Skip to content

Commit

Permalink
Update: Make debug logs clearer.
Browse files Browse the repository at this point in the history
  • Loading branch information
JurajNyiri committed Apr 22, 2021
1 parent 968bbad commit a2ffad5
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions custom_components/tapo_control/binary_sensor.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ async def async_setup_entry(hass, entry, async_add_entities):
for event in events.get_platform("binary_sensor")
}

LOGGER.debug("Adding binary sensor entity.")
LOGGER.debug("Creating binary sensor entity.")
async_add_entities(entities.values())

@callback
Expand All @@ -32,7 +32,9 @@ def async_check_entities():
for event in events.get_platform("binary_sensor"):
LOGGER.debug(event)
if event.uid not in entities:
LOGGER.debug("Found event which doesn't have entity yet, creating it.")
LOGGER.debug(
"Found event which doesn't have entity yet, adding binary sensor!"
)
entities[event.uid] = TapoBinarySensor(event.uid, events, name, camData)
new_entities.append(entities[event.uid])
async_add_entities(new_entities)
Expand Down

0 comments on commit a2ffad5

Please sign in to comment.