Fix Mikrotik encoding by setting utf8 (#38091)

pull/40212/head
Janis Jansons 2020-08-05 02:39:55 +03:00 committed by GitHub
parent 2d7b9326ee
commit 17c9e31e2c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -390,7 +390,7 @@ def get_api(hass, entry):
_LOGGER.debug("Connecting to Mikrotik hub [%s]", entry[CONF_HOST])
_login_method = (login_plain, login_token)
kwargs = {"login_methods": _login_method, "port": entry["port"]}
kwargs = {"login_methods": _login_method, "port": entry["port"], "encoding": "utf8"}
if entry[CONF_VERIFY_SSL]:
ssl_context = ssl.create_default_context()