mirror of
https://github.com/simple-login/app.git
synced 2024-11-18 06:31:27 +08:00
Add 405 error
This commit is contained in:
parent
5c8c741a6a
commit
ee19957d5d
1 changed files with 5 additions and 0 deletions
|
@ -44,3 +44,8 @@ def not_found(e):
|
|||
def internal_error(e):
|
||||
LOG.exception(e)
|
||||
return jsonify(error="Internal error"), 500
|
||||
|
||||
|
||||
@api_bp.app_errorhandler(405)
|
||||
def wrong_method(e):
|
||||
return jsonify(error="Method not allowed"), 405
|
||||
|
|
Loading…
Reference in a new issue