Skip to content

Commit

Permalink
fix logout
Browse files Browse the repository at this point in the history
  • Loading branch information
py3-dev committed Aug 8, 2024
1 parent cbf8516 commit b8c9293
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions backend/apps/hub/api/controller.py
Original file line number Diff line number Diff line change
Expand Up @@ -243,6 +243,10 @@ class CustomLoginView(LoginView):
template_name = 'hub/login.html'
next_page = '/'


from django.utils.decorators import method_decorator
from django.views.decorators.http import require_http_methods
@method_decorator(require_http_methods(["GET", "POST"]), name='dispatch')
class CustomLogoutView(LogoutView):
next_page = '/'
def get(self, request, *args, **kwargs):
Expand Down

0 comments on commit b8c9293

Please sign in to comment.