mirror of
https://github.com/umap-project/umap.git
synced 2025-04-29 11:52:38 +02:00
fix: be defensive when getting the backend name from the session
Seems that in some situation it is not defined.
This commit is contained in:
parent
c0f7e9d50d
commit
470fc14d6d
1 changed files with 1 additions and 1 deletions
|
@ -1421,7 +1421,7 @@ class LoginPopupEnd(TemplateView):
|
||||||
template_name = "umap/login_popup_end.html"
|
template_name = "umap/login_popup_end.html"
|
||||||
|
|
||||||
def get(self, *args, **kwargs):
|
def get(self, *args, **kwargs):
|
||||||
backend = self.request.session[BACKEND_SESSION_KEY]
|
backend = self.request.session.get(BACKEND_SESSION_KEY)
|
||||||
if backend in settings.DEPRECATED_AUTHENTICATION_BACKENDS:
|
if backend in settings.DEPRECATED_AUTHENTICATION_BACKENDS:
|
||||||
return HttpResponseRedirect(reverse("user_profile"))
|
return HttpResponseRedirect(reverse("user_profile"))
|
||||||
return super().get(*args, **kwargs)
|
return super().get(*args, **kwargs)
|
||||||
|
|
Loading…
Reference in a new issue