[Zope-Checkins] CVS: Zope3/lib/python/Zope/App/ZopePublication/AbsoluteURL - AbsoluteURL.py:1.1.2.3

Jim Fulton jim@zope.com
Sun, 28 Apr 2002 13:17:13 -0400


Update of /cvs-repository/Zope3/lib/python/Zope/App/ZopePublication/AbsoluteURL
In directory cvs.zope.org:/tmp/cvs-serv17050/lib/python/Zope/App/ZopePublication/AbsoluteURL

Modified Files:
      Tag: Zope-3x-branch
	AbsoluteURL.py 
Log Message:
HOTYB: Merged SecurityProxy-branch into main branch.  

All tests pass and folders can be listed and added through the web.
It is likely that most other things don't work and will need to be
fixed. The reason is that many accesses that should have been checked
before are now being checked and additional checks and thinking about
permissions and security settings are needed.

I'm in the process of drafting a paper for the wiki that describes the
changes in more detail.


=== Zope3/lib/python/Zope/App/ZopePublication/AbsoluteURL/AbsoluteURL.py 1.1.2.2 => 1.1.2.3 ===
 """
 from Zope.Publisher.Browser.IBrowserPublisher import IBrowserPublisher
-from Zope.ContextWrapper import getinnercontext, getdict
+from Zope.Proxy.ContextWrapper import getWrapperContainer, getWrapperData
 from Zope.ComponentArchitecture import getRequestView
 
 class AbsoluteURL:
@@ -32,9 +32,9 @@
 
     def __str__(self):
         context = self.__context
-        dict = getdict(context)
+        dict = getWrapperData(context)
         name = dict and dict.get('name') or None
-        container = getinnercontext(context)
+        container = getWrapperContainer(context)
         if name is None or container is None:
             raise TypeError, 'Not enough context information to get a URL'