From 2edd75de961cae2531f66ee172f94c277cfd8563 Mon Sep 17 00:00:00 2001 From: Shane Kilkelly Date: Tue, 22 Nov 2016 16:48:13 +0000 Subject: [PATCH] Allow the 500/Error page to render, even if res.locals aren't set up yet. --- services/web/app/views/general/500.jade | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/services/web/app/views/general/500.jade b/services/web/app/views/general/500.jade index ef74ed7435..8381ca6190 100644 --- a/services/web/app/views/general/500.jade +++ b/services/web/app/views/general/500.jade @@ -3,7 +3,8 @@ html(itemscope, itemtype='http://schema.org/Product') head title Something went wrong link(rel="icon", href="/favicon.ico") - link(rel='stylesheet', href=buildCssPath('/style.css')) + if buildCssPath + link(rel='stylesheet', href=buildCssPath('/style.css')) link(href="//netdna.bootstrapcdn.com/font-awesome/4.2.0/css/font-awesome.min.css",rel="stylesheet") body .content @@ -12,7 +13,9 @@ html(itemscope, itemtype='http://schema.org/Product') .col-md-8.col-md-offset-2.text-center .page-header h2 Oh dear, something went wrong. - p: img(src=buildImgPath("lion-sad-128.png"), alt="Sad Lion") + if buildImgPath + p + img(src=buildImgPath("lion-sad-128.png"), alt="Sad Lion") p | Something went wrong with your request, sorry. Our staff are probably looking into this, but if it continues, please contact us at #{settings.adminEmail} p