zemirco/lockit-utilities — pull request #2 by skyYaga (2014-08-05 16:43:09+00:00)
Title: updated res.redirect to use req.originalUrl

res.redirect will now use req.originalUrl as source url, so that the user will be forwarded correctly, if the application uses different route files, e.g. in app.js:

var admin = require('./routes/admin');
app.use('/admin', admin);

In admin.js:
router.get('/', utils.restrict(), function(req, res) {
// further implementation
}
...