diff --git a/src/middleware/middleware.js b/src/middleware/middleware.js index 6bab0678e6..e4e5ebbc6f 100644 --- a/src/middleware/middleware.js +++ b/src/middleware/middleware.js @@ -297,7 +297,7 @@ middleware.renderHeader = function(req, res, callback) { templateValues.customCSS = results.customCSS; templateValues.customJS = results.customJS; templateValues.maintenanceHeader = parseInt(meta.config.maintenanceMode, 10) === 1 && !results.isAdmin; - templateValues.defaultLang = res.locals.config.defaultLang; + templateValues.defaultLang = meta.config.defaultLang || 'en_GB'; templateValues.template = {name: res.locals.template}; templateValues.template[res.locals.template] = true;