aboutsummaryrefslogtreecommitdiffstats
path: root/users.js
diff options
context:
space:
mode:
Diffstat (limited to 'users.js')
-rw-r--r--users.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/users.js b/users.js
index db2168c1..ccfbc427 100644
--- a/users.js
+++ b/users.js
@@ -21,7 +21,7 @@ const twofa = (req, res, next) => {
user,
body: { token }
} = req;
- if (!user.twofa || authenticator.check(token, user.otpsecret)) next();
+ if (!user.twofa || authenticator.check(token, user.otpsecret)) next(req, res);
else res.status(401).send("2fa required");
};