Fix login when using python 3

Change-Id: I0185461daafc904fd5ad180cef0233ea75903b67
Story: 2000576
Task: 2978
This commit is contained in:
Adam Coldrick 2018-02-17 13:20:55 +00:00
parent 8a0893e8bf
commit ced228427e
1 changed files with 5 additions and 1 deletions

View File

@ -133,7 +133,11 @@ class OpenIdClient(object):
verify_response = requests.post(CONF.oauth.openid_url,
data=verify_params)
verify_data_tokens = verify_response.content.split()
content = verify_response.content
if isinstance(content, bytes):
content = content.decode('utf-8')
verify_data_tokens = content.split()
verify_dict = dict((token.split(":")[0], token.split(":")[1])
for token in verify_data_tokens)