migrating repo to Bodyrep org

This commit is contained in:
2013-01-19 11:23:43 -05:00
parent 31b7303f43
commit 4ea082330b
891 changed files with 142706 additions and 0 deletions

View File

@@ -0,0 +1,9 @@
function restrictUserToSelf(req, res, next) {
if (! req.session.user || req.session.user.username !== req.user.username) {
res.send('Unauthorized', 401);
} else {
next();
}
}
module.exports = restrictUserToSelf;