Skip to content

Commit

Permalink
handle 500
Browse files Browse the repository at this point in the history
  • Loading branch information
submarcos committed Apr 23, 2024
1 parent de7c8a3 commit ab894e8
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion georiviere/main/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,14 @@
from django.urls import reverse
from mapentity.registry import registry
from mapentity import views as mapentity_views
import logging


def handler500(request, *args, **kwargs):
logger = logging.getLogger(__name__)


def handler500(request, exception, *args, **kwargs):
logger.error('Internal Server Error: %s', str(exception))
return HttpResponse(status=500)


Expand Down

0 comments on commit ab894e8

Please sign in to comment.