mirror of
https://github.com/cwinfo/powerdns-admin.git
synced 2025-01-07 19:05:39 +00:00
commit
978c0b6c62
@ -201,7 +201,7 @@ def login():
|
|||||||
return redirect(url_for('index.index'))
|
return redirect(url_for('index.index'))
|
||||||
|
|
||||||
if 'azure_token' in session:
|
if 'azure_token' in session:
|
||||||
azure_info = azure.get('me?$select=displayName,givenName,id,mail,surname,userPrincipalName,preferredName').text
|
azure_info = azure.get('me?$select=displayName,givenName,id,mail,surname,userPrincipalName').text
|
||||||
current_app.logger.info('Azure login returned: '+azure_info)
|
current_app.logger.info('Azure login returned: '+azure_info)
|
||||||
me = json.loads(azure_info)
|
me = json.loads(azure_info)
|
||||||
|
|
||||||
@ -218,8 +218,8 @@ def login():
|
|||||||
azure_username = me["userPrincipalName"]
|
azure_username = me["userPrincipalName"]
|
||||||
azure_givenname = me["givenName"]
|
azure_givenname = me["givenName"]
|
||||||
azure_familyname = me["surname"]
|
azure_familyname = me["surname"]
|
||||||
if "email" in me:
|
if "mail" in me:
|
||||||
azure_email = me["email"]
|
azure_email = me["mail"]
|
||||||
else:
|
else:
|
||||||
azure_email = ""
|
azure_email = ""
|
||||||
if not azure_email:
|
if not azure_email:
|
||||||
|
Loading…
Reference in New Issue
Block a user