diff --git a/custom_components/mikrotik_router/mikrotikapi.py b/custom_components/mikrotik_router/mikrotikapi.py index 06c657e..b052fb8 100644 --- a/custom_components/mikrotik_router/mikrotikapi.py +++ b/custom_components/mikrotik_router/mikrotikapi.py @@ -363,6 +363,7 @@ class MikrotikAPI: args = {"interface": interfaces, "once": True} self.lock.acquire() try: + _LOGGER.debug("API query: %s", "/interface/monitor-traffic") traffic = response("monitor-traffic", **args) except librouteros_custom.exceptions.ConnectionClosed: self.disconnect() @@ -387,7 +388,7 @@ class MikrotikAPI: return None try: - tuple(response) + traffic = list(traffic) except librouteros_custom.exceptions.ConnectionClosed as api_error: self.disconnect("get_traffic", api_error) self.lock.release()