From 60c45d8b9b68c834327643e6d8edca3f55607981 Mon Sep 17 00:00:00 2001 From: Julian Lam Date: Fri, 3 Oct 2014 16:38:56 -0400 Subject: [PATCH] fixed issue where non-admins would get maintenance mode header if maintenance mode was NOT enabled (logic errors, grrr..) --- src/middleware/middleware.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/middleware/middleware.js b/src/middleware/middleware.js index 93080ea221..ee24f032ae 100644 --- a/src/middleware/middleware.js +++ b/src/middleware/middleware.js @@ -355,7 +355,7 @@ middleware.renderHeader = function(req, res, callback) { templateValues.user = results.user; templateValues.customCSS = results.customCSS; templateValues.customJS = results.customJS; - templateValues.maintenanceHeader = meta.config.maintenanceMode === '1' ^ !!results.isAdmin + templateValues.maintenanceHeader = meta.config.maintenanceMode === '1' && !results.isAdmin app.render('header', templateValues, callback); });