From fa0fd2b07ff3f47d470a651cb1b5c5d44d23e127 Mon Sep 17 00:00:00 2001 From: Andrew Davidson Date: Sat, 23 Jan 2016 17:30:24 -0500 Subject: [PATCH] Reducing the double env === development --- app.js | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/app.js b/app.js index 36ba8aa..a7d0096 100644 --- a/app.js +++ b/app.js @@ -50,9 +50,6 @@ app.use(session({ app.use(express.static(path.join(__dirname, 'public'))); -if (app.get('env') === 'development') { - app.locals.pretty = true; -} // Setup authentication via twitter. passport.use(new Strategy( @@ -148,6 +145,7 @@ app.use(function(req, res, next) { // development error handler // will print stacktrace if (app.get('env') === 'development') { + app.locals.pretty = true; app.use(function(err, req, res, next) { res.status(err.status || 500); res.render('admin-error', {