Merge pull request #10808 from demarches-simplifiees/fix-missing-expiration
Fix missing expiration after refacto
This commit is contained in:
commit
f9994245f1
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