mirror of
https://github.com/sudoxnym/habitica.git
synced 2026-08-04 09:39:23 +00:00
redirect 500.html on error
This commit is contained in:
parent
3dc9bad6ae
commit
8d01cbbc21
1 changed files with 4 additions and 1 deletions
|
|
@ -14,5 +14,8 @@ module.exports = (root) ->
|
|||
status = parseInt message
|
||||
if status is 404
|
||||
staticPages.render '404', res, {url: req.url}, 404
|
||||
else if status >= 400 and status < 600
|
||||
res.send status
|
||||
else
|
||||
res.send if 400 <= status < 600 then status else 500
|
||||
#TODO send error to email
|
||||
res.redirect('/500.html')
|
||||
Loading…
Reference in a new issue