flows: fix SESSION_KEY_GET being deleted too early

This commit is contained in:
Jens Langhammer 2020-07-14 21:42:47 +02:00
parent 5f34b08433
commit fbf9554a9e

View file

@ -152,11 +152,12 @@ class FlowExecutorView(View):
def _flow_done(self) -> HttpResponse:
"""User Successfully passed all stages"""
self.cancel()
# Since this is wrapped by the ExecutorShell, the next argument is saved in the session
# extract the next param before cancel as that cleans it
next_param = self.request.session.get(SESSION_KEY_GET, {}).get(
NEXT_ARG_NAME, "passbook_core:overview"
)
self.cancel()
return redirect_with_qs(next_param)
def stage_ok(self) -> HttpResponse: