mirror of
https://github.com/snobu/destreamer.git
synced 2026-01-27 10:22:21 +00:00
fixed stupid session refreshing typo
This commit is contained in:
@@ -52,7 +52,7 @@ export class TokenCache {
|
||||
public isExpiring(session: Session): [boolean, number] {
|
||||
const decodedJwt: Jwt = jwtDecode(session.AccessToken);
|
||||
|
||||
const timeLeft: number = decodedJwt['exp']; - Math.floor(Date.now() / 1000);
|
||||
const timeLeft: number = decodedJwt['exp'] - Math.floor(Date.now() / 1000);
|
||||
|
||||
if (timeLeft < (5 * 60)) {
|
||||
return [true, 0];
|
||||
|
||||
Reference in New Issue
Block a user