mirror of
https://github.com/TryGhost/Ghost.git
synced 2025-02-24 23:48:13 -05:00
refs #6982 - a replace for all config usages - always use config.get or config.set - this a pure replacement, no logic has changed [ci skip]
13 lines
321 B
JavaScript
13 lines
321 B
JavaScript
var config = require('../config'),
|
|
i18n = require('../i18n'),
|
|
errors = require('../errors');
|
|
|
|
module.exports = function (req, res, next) {
|
|
if (config.get('maintenance').enabled) {
|
|
return next(new errors.Maintenance(
|
|
i18n.t('errors.general.maintenance')
|
|
));
|
|
}
|
|
|
|
next();
|
|
};
|