Skip to content

Commit

Permalink
missed by rebase
Browse files Browse the repository at this point in the history
  • Loading branch information
jkachel committed Sep 23, 2024
1 parent c133e92 commit 83fd805
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions unified_ecommerce/middleware.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

import logging

from django.contrib.auth import login
from django.contrib.auth import login, logout
from django.contrib.auth.middleware import RemoteUserMiddleware
from django.core.exceptions import ImproperlyConfigured

Expand All @@ -29,7 +29,7 @@ def process_request(self, request):
except KeyError:
if self.force_logout_if_no_header and request.user.is_authenticated:
logout(request)
return
return None

if apisix_user:
if request.user.is_authenticated and request.user != apisix_user:
Expand Down

0 comments on commit 83fd805

Please sign in to comment.