forked from 00dani/lemoncurry
Switch from PyJWT to python-jose, since it supports more features and has more documentation
This commit is contained in:
parent
5b70c59f83
commit
cfe0f47d0f
3 changed files with 32 additions and 13 deletions
|
@ -1,4 +1,4 @@
|
|||
import jwt
|
||||
from jose import jwt
|
||||
|
||||
from datetime import datetime, timedelta
|
||||
from django.conf import settings
|
||||
|
@ -34,4 +34,4 @@ def gen_token(code):
|
|||
'sco': code['sco'],
|
||||
'iat': datetime.utcnow(),
|
||||
}
|
||||
return encode(tok).decode('utf-8')
|
||||
return encode(tok)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue