diff --git a/src/routes/auth.js b/src/routes/auth.js index 2f0da93..7b820d7 100644 --- a/src/routes/auth.js +++ b/src/routes/auth.js @@ -96,13 +96,13 @@ export const authRoutes = (fastify, _, done) => { } }) - // response.setCookie("token", session_id, { - // httpOnly: false, - // path: "/", - // sameSite: false, - // maxAge: 1000 * 60 * 60 * 24 * 7, - // domain: ".omersabic.com" - // }).redirect(env.FRONTEND_URL); + reply.setCookie("token", session_id, { + httpOnly: true, + path: "/", + sameSite: false, + maxAge: 1000 * 60 * 60 * 24 * 7, + domain: "api.youpage.ai" + }); reply.redirect(env.FRONTEND_URL + "/auth?token=" + session_id);