mirror of
https://github.com/nextcloud/server.git
synced 2026-05-28 04:32:30 -04:00
Also adjust the expiration of PublicKeyTokenProvider
Signed-off-by: Joas Schilling <coding@schilljs.com>
This commit is contained in:
parent
5e6187926f
commit
f258e65f13
1 changed files with 2 additions and 2 deletions
|
|
@ -80,7 +80,7 @@ class PublicKeyTokenProvider implements IProvider {
|
|||
throw new InvalidTokenException();
|
||||
}
|
||||
|
||||
if ($token->getExpires() !== null && $token->getExpires() !== 0 && $token->getExpires() < $this->time->getTime()) {
|
||||
if ((int)$token->getExpires() !== 0 && $token->getExpires() < $this->time->getTime()) {
|
||||
throw new ExpiredTokenException($token);
|
||||
}
|
||||
|
||||
|
|
@ -94,7 +94,7 @@ class PublicKeyTokenProvider implements IProvider {
|
|||
throw new InvalidTokenException();
|
||||
}
|
||||
|
||||
if ($token->getExpires() !== null && $token->getExpires() < $this->time->getTime()) {
|
||||
if ((int)$token->getExpires() !== 0 && $token->getExpires() < $this->time->getTime()) {
|
||||
throw new ExpiredTokenException($token);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue