Bug fix OAuth

This commit is contained in:
Edward Betts 2019-09-27 20:06:22 +01:00
parent f5efbf1d85
commit 57e2f46d77

3
app.py
View file

@ -245,7 +245,8 @@ def get_username():
return session['username']
params = {'action': 'query', 'meta': 'userinfo', 'format': 'json'}
session['username'] = oauth_api_request(params)['query']['userinfo']['name']
r = oauth_api_request(params)
session['username'] = r.json()['query']['userinfo']['name']
return session['username']