def auth(self): request = self.request # log out request if request.POST.get("persona", None) == "-1": request.response.merge_cookies(logout(request)) request.session.invalidate() request.user = None form_style = request.user and "form-horizontal" or "form-vertical" return auth(request)(request, action="app", bootstrap_form_style=form_style, formid="auth")
def persona(self): request = self.request # logout request if request.params.get('persona', None) == '-1': request.add_response_callback( lambda req, res: logout(req).merge_cookies(res)) request.user = None return persona( request, bootstrap_form_style='form-horizontal', formid='persona', )
def persona(self): request = self.request # logout request if request.params.get('persona', None) == '-1': request.add_response_callback( lambda req, res: logout(req).merge_cookies(res) ) request.user = None return persona( request, bootstrap_form_style='form-horizontal', formid='persona', )