diff --git a/app.py b/app.py index 9ed66e8..7720b3d 100644 --- a/app.py +++ b/app.py @@ -130,11 +130,15 @@ def is_safe_url(target): @app.errorhandler(404) -@app.errorhandler(500) def not_found(e): return flask.render_template('error/{}.html'.format(e.code)), e.code +@app.errorhandler(500) +def server_error(exc): + return flask.render_template('error/500.html'), 500 + + @app.route('/') def index(): return flask.render_template('index.html')