Fix missing expiration after refacto
This commit is contained in:
parent
c902061ebf
commit
8384be12a0
1 changed files with 1 additions and 0 deletions
|
@ -10,6 +10,7 @@ class JwtField < Administrate::Field::Base
|
|||
|
||||
return "Token présent, sans expiration" unless decoded_token[0].key?('exp')
|
||||
|
||||
expiration = Time.zone.at(decoded_token[0]['exp'])
|
||||
if expiration < Time.zone.now
|
||||
"Token présent, expiré le #{expiration.strftime('%d/%m/%Y à %H:%M')}"
|
||||
else
|
||||
|
|
Loading…
Reference in a new issue