Reduced line length

1.0
Jildert Miedema 2014-10-27 10:42:39 +01:00
parent 375a737b9b
commit d02b238bc2
1 changed files with 3 additions and 1 deletions

View File

@ -60,7 +60,9 @@ class AccessToken
} elseif (!empty($options['expires'])) {
// Some providers supply the seconds until expiration rather than
// the exact timestamp. Take a best guess at which we received.
$this->expires = ($options['expires'] > time()) ? $options['expires'] : time() + ((int) $options['expires']);
$expires = $options['expires'];
$expiresInFuture = $expires > time();
$this->expires = $expiresInFuture ? $expires : time() + ((int) $expires);
}
// Grab a refresh token so we can update access tokens when they expires