diff --git a/app.js b/app.js index 312b505..d93de6c 100644 --- a/app.js +++ b/app.js @@ -66,6 +66,9 @@ function initApp (config, callback) { app.express.use(function (err, req, res, next) { /* jshint unused: false */ app.emit('route-error', err); + if (process.env.NODE_ENV !== 'production') { + res.locals.error = err; + } res.status(500); res.render('500'); }); diff --git a/view/500.html b/view/500.html index 58e0cce..3165123 100644 --- a/view/500.html +++ b/view/500.html @@ -2,8 +2,10 @@
There isn't much you can do about this.
Give it another go or try the home page. -
Techy-stuff
-<p>Sample text here...</p>+ {{#if error}} +
{{error.stack}}+ {{/if}}