Skip to content
This repository has been archived by the owner on Sep 11, 2024. It is now read-only.

Commit

Permalink
Fixes typo in error codes passed to templates (#2)
Browse files Browse the repository at this point in the history
* Fixes typo in error codes passed to templates

* Bumps the patch version
  • Loading branch information
djperrefort authored Jun 7, 2022
1 parent 05614e9 commit 4c62bd3
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion django_easy_error/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@

from django.conf import settings

__version__ = '1.0.1'
__version__ = '1.0.2'
__author__ = 'Daniel Perrefort'

# Allow reloading of the module without Django raising an error
Expand Down
6 changes: 3 additions & 3 deletions django_easy_error/handlers.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,13 @@
def handler400(request: HttpRequest, exception: int) -> HttpResponse:
"""Render a response to a 400 error"""

return error_render(404, request)
return error_render(400, request)


def handler403(request: HttpRequest, exception: int) -> HttpResponse:
"""Render a response to a 403 error"""

return error_render(404, request)
return error_render(403, request)


def handler404(request: HttpRequest, exception: int) -> HttpResponse:
Expand All @@ -33,4 +33,4 @@ def handler404(request: HttpRequest, exception: int) -> HttpResponse:
def handler500(request: HttpRequest) -> HttpResponse:
"""Render a response to a 500 error"""

return error_render(404, request)
return error_render(500, request)

0 comments on commit 4c62bd3

Please sign in to comment.