Permalink
Browse files

Better refreshing when an error occurs.

  • Loading branch information...
Ian Langworth ☠
Ian Langworth ☠ committed Mar 21, 2013
1 parent 5a77a3c commit 6aa20697f8af95c864cc3c76fcd6d7113b4c32d0
Showing with 12 additions and 1 deletion.
  1. +12 −1 prviewer.coffee
View
@@ -309,7 +309,18 @@ app.get '/', ensureAuthenticated, (req, res) ->
], (err, pulls) ->
if err
- res.send 500, "Error: #{ err }"
+ res.send """
+ <html>
+ <head>
+ <meta http-equiv="refresh" content="3"/>
+ <head>
+ <body>
+ Error: <code>#{ require('util').inspect err }</code>
+ <br/>
+ Refreshing in a few seconds...
+ </body>
+ </head>
+ """
else
res.render 'index',
settings: settings

0 comments on commit 6aa2069

Please sign in to comment.