add test log
This commit is contained in:
parent
5071250dab
commit
c0e0b5908b
2
main.py
2
main.py
@ -516,10 +516,12 @@ def auth_get():
|
|||||||
# Check if user is valid
|
# Check if user is valid
|
||||||
r = requests.get(f'https://login.hns.au/auth/user?token={token}')
|
r = requests.get(f'https://login.hns.au/auth/user?token={token}')
|
||||||
if r.status_code != 200:
|
if r.status_code != 200:
|
||||||
|
print(r.text,flush=True)
|
||||||
return redirect('/?error=Failed to login&reason=Failed to connect to HNS Login')
|
return redirect('/?error=Failed to login&reason=Failed to connect to HNS Login')
|
||||||
try:
|
try:
|
||||||
r = r.json()
|
r = r.json()
|
||||||
except:
|
except:
|
||||||
|
print(r.text,flush=True)
|
||||||
return redirect('/?error=Failed to login&reason=Failed to connect to HNS Login')
|
return redirect('/?error=Failed to login&reason=Failed to connect to HNS Login')
|
||||||
|
|
||||||
if 'error' in r:
|
if 'error' in r:
|
||||||
|
Loading…
Reference in New Issue
Block a user