2
0
mirror of https://github.com/xcat2/confluent.git synced 2024-11-22 17:43:14 +00:00

Fix non-root user issue with python3

This commit is contained in:
Jarrod Johnson 2019-10-10 16:04:23 -04:00
parent f28b91499e
commit 9eceda0636

View File

@ -119,6 +119,8 @@ def _get_usertenant(name, tenant=False):
administrator account a tenant gets.
Otherwise, just assume a user in the default tenant
"""
if not isinstance(name, bytes):
name = name.encode('utf-8')
if not isinstance(tenant, bool):
# if not boolean, it must be explicit tenant
user = name