Skip to content

Commit 34ada58

Browse files
committed
fix type
1 parent 2cc5a8c commit 34ada58

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/examples/server/demoInMemoryOAuthProvider.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,7 @@ export class DemoInMemoryAuthProvider implements OAuthServerProvider {
118118

119119
async verifyAccessToken(token: string): Promise<AuthInfo> {
120120
const tokenData = this.tokens.get(token);
121-
if (!tokenData || tokenData.expiresAt < Date.now() || tokenData.type === 'refresh') {
121+
if (!tokenData || !tokenData.expiresAt || tokenData.expiresAt < Date.now()) {
122122
throw new Error('Invalid or expired token');
123123
}
124124

0 commit comments

Comments
 (0)