Skip to content

Commit 70862fd

Browse files
committed
Ignore JWT sub test if user id is not provided
1 parent 8a68d2c commit 70862fd

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Adapters/Auth/google.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,7 @@ async function verifyIdToken({id_token: token, id}, {clientId}) {
8888
);
8989
}
9090

91-
if (jwtClaims.sub !== id) {
91+
if (typeof id != "undefined" && jwtClaims.sub !== id) {
9292
throw new Parse.Error(Parse.Error.OBJECT_NOT_FOUND, `auth data is invalid for this user.`);
9393
}
9494

0 commit comments

Comments
 (0)