fix: use id to sign jwt token for google oauth callback
This commit is contained in:
@@ -366,7 +366,7 @@ router.get(
|
||||
|
||||
// Generate JWT token for session
|
||||
const jwtToken = jwt.sign(
|
||||
{ userId: user.id },
|
||||
{ id: user.id },
|
||||
process.env.JWT_SECRET as string
|
||||
);
|
||||
res.cookie("token", jwtToken, { httpOnly: true });
|
||||
|
||||
Reference in New Issue
Block a user