Update src/api/users/auth.route.js

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
This commit is contained in:
Charmunk 2025-11-10 12:42:43 -05:00 committed by GitHub
parent 24b7a8c515
commit d3ada5a689
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -212,7 +212,7 @@ router.post('/login', /* authLimiter, */ async (req, res) => {
.returning(['email', 'username', 'authorization', 'is_admin']);
res.cookie('auth_token', updatedUser.authorization, {
httpOnly: false,
httpOnly: true,
maxAge: 7 * 24 * 60 * 60 * 1000,
sameSite: 'strict',
secure: process.env.NODE_ENV === 'production'