logo       
Google Custom Search
    AddThis Social Bookmark Button
-->

CVS: CMF/CMFCore - CookieCrumbler.py:1.25: msg#00086

Subject: CVS: CMF/CMFCore - CookieCrumbler.py:1.25
Update of /cvs-repository/CMF/CMFCore
In directory cvs.zope.org:/tmp/cvs-serv684

Modified Files:
        CookieCrumbler.py 
Log Message:
Made compatible with Zope 2.7.


=== CMF/CMFCore/CookieCrumbler.py 1.24 => 1.25 ===
--- CMF/CMFCore/CookieCrumbler.py:1.24  Fri Dec  5 17:16:12 2003
+++ CMF/CMFCore/CookieCrumbler.py       Thu Jan 22 11:43:49 2004
@@ -31,6 +31,12 @@
 from CMFCorePermissions import ViewManagementScreens
 from utils import SimpleItemWithProperties
 
+try:
+    from zExceptions import Redirect
+except ImportError:
+    # Pre Zope 2.7
+    Redirect = 'Redirect'
+
 
 # Constants.
 ATTEMPT_NONE = 0       # No attempt at authentication
@@ -251,7 +257,7 @@
         # Redirect if desired.
         url = self.getUnauthorizedURL()
         if url is not None:
-            raise 'Redirect', url
+            raise Redirect, url
         # Fall through to the standard unauthorized() call.
         resp.unauthorized()


<Prev in Thread] Current Thread [Next in Thread>