diff options
author | John Molakvoæ <skjnldsv@users.noreply.github.com> | 2018-06-11 09:17:29 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-06-11 09:17:29 +0200 |
commit | 07f5a2d44828cb5bfd3620d9a9159110a1c74e98 (patch) | |
tree | 3aefd51a9b9dd34689dbdb0eef5df0cc078c5c94 | |
parent | 2dc7696dda3541e416ce64433690679548511416 (diff) | |
parent | a5a272e5d4f1dd11295ecef3c2c8c6724eee29df (diff) | |
download | nextcloud-server-07f5a2d44828cb5bfd3620d9a9159110a1c74e98.tar.gz nextcloud-server-07f5a2d44828cb5bfd3620d9a9159110a1c74e98.zip |
Merge pull request #9804 from nextcloud/backport/9802/stable12
[stable12] Make the token expiration also work for autocasting 0
-rw-r--r-- | lib/private/Authentication/Token/DefaultTokenProvider.php | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/private/Authentication/Token/DefaultTokenProvider.php b/lib/private/Authentication/Token/DefaultTokenProvider.php index eee4db20af9..dd7829cc68c 100644 --- a/lib/private/Authentication/Token/DefaultTokenProvider.php +++ b/lib/private/Authentication/Token/DefaultTokenProvider.php @@ -159,7 +159,7 @@ class DefaultTokenProvider 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); } |