fix: token exp

This commit is contained in:
Peng Xiao 2023-02-09 23:12:36 +08:00
parent ee2e1687df
commit 385e9afba6

View File

@ -126,7 +126,8 @@ export class Token {
get isExpired() {
if (!this._user) return true;
return Date.now() > this._user.exp;
// exp is in seconds
return Date.now() > this._user.exp * 1000;
}
static parse(token: string): AccessTokenMessage | null {