Skip to content

Commit 543a991

Browse files
committed
fix: users are redirected to the page they expected when logging in
1 parent c69fdad commit 543a991

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

custom_auth/views.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,8 @@ class ClientIdLoginView(views.LoginView):
8686
def get_context_data(self, **kwargs):
8787
context = super(views.LoginView, self).get_context_data(**kwargs)
8888
context["googlefail"] = self.request.GET.get("error", "") == "googlefail"
89+
context["next"] = self.request.GET.get("next", settings.LOGIN_REDIRECT_URL)
90+
8991
context.update(self.extra_context)
9092

9193
return context

0 commit comments

Comments
 (0)