mirror of
https://github.com/netbox-community/netbox.git
synced 2025-07-22 03:56:53 -06:00
Tweaked exception-handling middleware to preserve tracebacks
This commit is contained in:
parent
c33775d71e
commit
2519ebff9d
@ -57,9 +57,9 @@ class ExceptionHandlingMiddleware(object):
|
||||
|
||||
def process_exception(self, request, exception):
|
||||
|
||||
# Raise exceptions if in debug mode
|
||||
# Don't catch exceptions when in debug mode
|
||||
if settings.DEBUG:
|
||||
raise exception
|
||||
return
|
||||
|
||||
# Determine the type of exception
|
||||
if isinstance(exception, ProgrammingError):
|
||||
|
Loading…
Reference in New Issue
Block a user