diff --git a/src/middleware/index.js b/src/middleware/index.js index 8f8f8a8002..b32b9147a4 100644 --- a/src/middleware/index.js +++ b/src/middleware/index.js @@ -79,7 +79,7 @@ middleware.ensureSelfOrPrivileged = function (req, res, next) { middleware.exposeUid prior to invoking this middleware. */ if (req.user) { - if (req.user.uid === res.locals.uid) { + if (parseInt(req.user.uid, 10) === parseInt(res.locals.uid, 10)) { return next(); }