From 7068d0983a29eb411bcd361ef8b764a8d10684ed Mon Sep 17 00:00:00 2001 From: Elliott King <8884571+elliott-king@users.noreply.github.com> Date: Wed, 27 Jan 2021 12:08:02 -0500 Subject: [PATCH] Clarify json error handling --- docs/blueprints.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/blueprints.rst b/docs/blueprints.rst index dbad7826..3bc11893 100644 --- a/docs/blueprints.rst +++ b/docs/blueprints.rst @@ -270,7 +270,7 @@ at the application level using the ``request`` proxy object:: @app.errorhandler(405) def _handle_api_error(ex): if request.path.startswith('/api/'): - return jsonify_error(ex) + return jsonify(error=str(ex)), ex.code else: return ex