auth
All checks were successful
Build & Push Image / build-image (push) Successful in 1m20s

This commit is contained in:
Ali
2026-02-24 21:57:25 +09:00
parent a12b65a488
commit 0a488a80ce
2 changed files with 19 additions and 29 deletions

View File

@@ -59,9 +59,9 @@ router.post('/login', async (req, res) => {
const token = jwt.sign({ id: user.id }, process.env.JWT_SECRET, { expiresIn: '24h' })
res.json({ token })
} catch (err) {
console.log(err.message)
res.sendStatus(503)
}
console.error("LOGIN ROUTE ERROR:", err);
res.status(500).json({ message: "Server error during login" });
}
})