mirror of https://github.com/veops/cmdb.git
auth: add user in flask.g when auth by jwt
This commit is contained in:
parent
d2f3589154
commit
82c921bb88
|
@ -53,6 +53,7 @@ def _auth_with_token():
|
||||||
return False
|
return False
|
||||||
|
|
||||||
login_user(user)
|
login_user(user)
|
||||||
|
g.user = user
|
||||||
return True
|
return True
|
||||||
except jwt.ExpiredSignatureError:
|
except jwt.ExpiredSignatureError:
|
||||||
return False
|
return False
|
||||||
|
|
Loading…
Reference in New Issue