mirror of
https://github.com/mountain-loop/yaak.git
synced 2026-11-19 06:58:24 +01:00
Fix access token refreshing
This commit is contained in:
1 parent
dfaeda224d
commit
493e844c01
1 file changed
+1
-1
@@ -22,7 +22,7 @@ export async function getOrRefreshAccessToken(ctx: Context, contextId: string, {
|
||||
return null;
|
||||
}
|
||||
|
||||
const now = (Date.now() / 1000);
|
||||
const now = Date.now();
|
||||
const isExpired = token.expiresAt && now > token.expiresAt;
|
||||
|
||||
// Return the current access token if it's still valid
|
||||
|
||||
Reference in new issue
Block a user