redirect to logout on unlink

This commit is contained in:
Benjamin Dauvergne 2017-03-21 17:00:48 +01:00
parent 321651c6b2
commit 7b0517e1dd
1 changed files with 2 additions and 5 deletions

View File

@ -381,12 +381,9 @@ class UnlinkView(LoggerMixin, SingleObjectMixin, FormView):
template_name = 'authentic2_auth_fc/unlink.html'
def get_success_url(self):
next = app_settings.logout_at_unlink_return_url
if app_settings.logout_when_unlink:
target = utils.build_logout_url(self.request, next)
if target:
next = target
return next
return reverse('auth_logout')
return reverse('account_management')
def get_form_class(self):
form_class = Form