Commit b77758cf authored by Guillaume Lebigot's avatar Guillaume Lebigot

Valid comparisons of dates work better

parent e41827f0
Pipeline #12063 passed with stage
in 1 minute and 2 seconds
......@@ -14,7 +14,7 @@ export const requireValidUser = (req, res, next) => {
if (!user) {
res.status(403).send('User logged in unknown');
} else {
if (token.password_last_modified_at !== user.password_last_modified_at) {
if (token.password_last_modified_at !== user.password_last_modified_at.toISOString()) {
res.status(403).send('Token has expired');
} else {
next();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment