sources/oauth: don't cancel flow when redirecting

Signed-off-by: Jens Langhammer <jens.langhammer@beryju.org>
This commit is contained in:
Jens Langhammer 2021-09-10 16:36:10 +02:00
parent 9a79bab43d
commit 39b365c6ae

View file

@ -6,7 +6,6 @@ from django.urls import reverse
from django.views.generic import RedirectView
from structlog.stdlib import get_logger
from authentik.flows.views import FlowExecutorView
from authentik.sources.oauth.models import OAuthSource
from authentik.sources.oauth.views.base import OAuthClientMixin
@ -43,5 +42,4 @@ class OAuthRedirect(OAuthClientMixin, RedirectView):
raise Http404(f"source {slug} is not enabled.")
client = self.get_client(source, callback=self.get_callback_url(source))
params = self.get_additional_parameters(source)
FlowExecutorView(request=self.request).cancel()
return client.get_redirect_url(params)