Commit 71e389ce authored by janis.streib's avatar janis.streib 🦉
Browse files

ADD: handle 404 page

parent daf966db
......@@ -132,6 +132,10 @@ def handle_db_error(e):
return jsonify({'type': 'generic_error', 'error': e}), 500
@app.errorhandler(404)
def handle_not_found(e):
return jsonify({'type': 'not found', 'error': str(e)}), 404
@app.errorhandler(Exception)
def handle_generic(e):
if app.config.get('DEBUG', False):
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment