Skip to content
Snippets Groups Projects
Commit ab378f69 authored by Guillaume WANG's avatar Guillaume WANG
Browse files

fix typo

parent 7ac005d9
No related branches found
No related tags found
No related merge requests found
...@@ -57,6 +57,8 @@ function ensureIsAdmin(returnTo) { ...@@ -57,6 +57,8 @@ function ensureIsAdmin(returnTo) {
// lookup req.user against whitelist of admin users // lookup req.user against whitelist of admin users
if (req.user && whitelist.includes(req.user.uid)) { if (req.user && whitelist.includes(req.user.uid)) {
console.log("is an admin"); console.log("is an admin");
// go on
next();
} else { } else {
console.log("is NOT an admin"); console.log("is NOT an admin");
req.flash('error: not an admin'); req.flash('error: not an admin');
...@@ -64,7 +66,7 @@ function ensureIsAdmin(returnTo) { ...@@ -64,7 +66,7 @@ function ensureIsAdmin(returnTo) {
res.redirect(returnTo); res.redirect(returnTo);
} }
// go on // go on
next(); //next();
}; };
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment