aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/app.js
diff options
context:
space:
mode:
Diffstat (limited to 'src/app.js')
-rw-r--r--src/app.js18
1 files changed, 9 insertions, 9 deletions
diff --git a/src/app.js b/src/app.js
index 2770943..0b0b3cd 100644
--- a/src/app.js
+++ b/src/app.js
@@ -12,7 +12,7 @@ app.set('views', path.join(__dirname, '../views'));
app.set('view engine', 'pug');
app.use(logger('dev', {
- skip: () => app.get('env') === 'test'
+ skip: () => app.get('env') === 'test'
}));
app.use(bodyParser.json());
app.use(bodyParser.urlencoded({extended: false}));
@@ -23,18 +23,18 @@ app.use('/', routes);
// Catch 404 and forward to error handler
app.use((req, res, next) => {
- const err = new Error('Not Found');
- err.status = 404;
- next(err);
+ const err = new Error('Not Found');
+ err.status = 404;
+ next(err);
});
// Error handler
app.use((err, req, res, next) => { // eslint-disable-line no-unused-vars
- res
- .status(err.status || 500)
- .render('error', {
- message: err.message
- });
+ res
+ .status(err.status || 500)
+ .render('error', {
+ message: err.message
+ });
});
export default app;