Modified checking of sensor type name logic to prevent false positives. Removed excessive logging.

This commit is contained in:
Ivan Pavlina 2022-01-02 08:17:58 +00:00
parent e93b02e71d
commit 7ffb5202ec
2 changed files with 22 additions and 25 deletions

View file

@ -614,10 +614,8 @@ class MikrotikControllerData:
if self.api.connected() and self.option_sensor_client_traffic:
if 0 < self.major_fw_version < 7:
_LOGGER.info("Using accounting feature for client traffic processing")
await self.hass.async_add_executor_job(self.process_accounting)
elif 0 < self.major_fw_version >= 7:
_LOGGER.info("Using accounting kid control devices for client traffic processing")
await self.hass.async_add_executor_job(self.process_kid_control_devices)
if self.api.connected() and self.option_sensor_simple_queues:
@ -2172,4 +2170,3 @@ class MikrotikControllerData:
break
return uid