python3: user-id generation in user_import

This commit is contained in:
Paul Marillonnet 2020-02-07 12:47:36 +01:00
parent cb976dc34e
commit 5cda45d69f
1 changed files with 2 additions and 2 deletions

View File

@ -43,8 +43,8 @@ logger = logging.getLogger(__name__)
def new_id():
return (base64.b32encode(uuid.uuid4().get_bytes())
.strip('=')
return (base64.b32encode(uuid.uuid4().bytes)
.strip(b'=')
.lower()
.decode('ascii'))