0
0
mirror of https://github.com/naturalcrit/homebrewery.git synced 2026-01-13 06:32:39 +00:00

All tests should be done, phew

This commit is contained in:
Scott Tolksdorf
2017-01-28 12:25:26 -05:00
parent 26bcb3395a
commit 75111acefb
6 changed files with 289 additions and 117 deletions

View File

@@ -16,6 +16,7 @@ const Middleware = {
return next();
},
admin : (req, res, next) => {
req.admin = false;
if(req.headers['x-homebrew-admin'] === config.get('admin:key')){
req.admin = true;
}
@@ -44,6 +45,7 @@ const Middleware = {
},
//TODO: REMOVE
//Loaders
loadBrew : (req, res, next) => {
BrewData.getByEdit(req.params.editId)