예제 #1
0
 def render(self):
     nextURL = self.request.get('nextURL')
     if IUnauthenticatedPrincipal(self.request.principal, False):
         component.getUtility(IAuthentication).unauthorized(
             self.request.principal.id, self.request)
         return self.failed()
     if nextURL is None:
         return self.confirmation()
     self.request.response.redirect(nextURL)
예제 #2
0
 def render(self):
     nextURL = self.request.get('nextURL')
     if not IUnauthenticatedPrincipal(self.request.principal, False):
         auth = component.getUtility(IAuthentication)
         ILogout(auth).logout(self.request)
         if nextURL:
             return self.redirect()
     if nextURL is None:
         return self.confirmation()
     return self.request.response.redirect(nextURL)
예제 #3
0
 def render(self):
     nextURL = self.request.get('nextURL')
     if IUnauthenticatedPrincipal(self.request.principal, False):
         # changed by Christian Luück
         component.getUtility(IAuthentication,
                              context=self.context).unauthorized(
                                  self.request.principal.id, self.request)
         return self.failed()
     if nextURL is None:
         return self.confirmation()
     self.request.response.redirect(nextURL)