Skip to content

Commit

Permalink
Corrected docs and removed unused code for got_request_exception sign…
Browse files Browse the repository at this point in the history
…al's sender argument.

Inaccurate since 7d1b69d.
  • Loading branch information
timgraham committed Nov 20, 2018
1 parent cafb349 commit 3529d0e
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions django/core/handlers/exception.py
Original file line number Diff line number Diff line change
Expand Up @@ -102,12 +102,12 @@ def response_for_exception(request, exc):
return response


def get_exception_response(request, resolver, status_code, exception, sender=None):
def get_exception_response(request, resolver, status_code, exception):
try:
callback, param_dict = resolver.resolve_error_handler(status_code)
response = callback(request, **{**param_dict, 'exception': exception})
except Exception:
signals.got_request_exception.send(sender=sender, request=request)
signals.got_request_exception.send(sender=None, request=request)
response = handle_uncaught_exception(request, resolver, sys.exc_info())

return response
Expand Down
2 changes: 1 addition & 1 deletion docs/ref/signals.txt
Original file line number Diff line number Diff line change
Expand Up @@ -547,7 +547,7 @@ This signal is sent whenever Django encounters an exception while processing an
Arguments sent with this signal:

``sender``
The handler class, as above.
Unused (always ``None``).

``request``
The :class:`~django.http.HttpRequest` object.
Expand Down

0 comments on commit 3529d0e

Please sign in to comment.