Skip to content
Myr

Makes the error names consistent

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by Sean Cronin · committed by Sean Cronin · parent 5d20501 · Browse files · 1 file+1 added−1 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+1 added−1 removed

  • other:+1 added−1 removed

1 file+1 added−1 removed

modified:docs/patterns/apierrors.rst+1 added-1 removed
45 unmodified lines
46At that point views can raise that error, but it would immediately result47in an internal server error. The reason for this is that there is no48handler registered for this error class. That however is easy to add::4950 @app.errorhandler(InvalidAPIUsage)50 @app.errorhandler(InvalidUsage)51 def handle_invalid_usage(error):52 response = jsonify(error.to_dict())53 response.status_code = error.status_code54 return response
9 unmodified lines