[Zope-Checkins] SVN: Zope/branches/philikon-aq/lib/python/Products/
Get rid of our custom ProviderExpression class,
just alias the name to the
Philipp von Weitershausen
philikon at philikon.de
Sun Jul 29 18:15:48 EDT 2007
Log message for revision 78475:
Get rid of our custom ProviderExpression class, just alias the name to the
implementation from Zope 3.
Changed:
U Zope/branches/philikon-aq/lib/python/Products/Five/browser/providerexpression.py
U Zope/branches/philikon-aq/lib/python/Products/PageTemplates/Expressions.py
-=-
Modified: Zope/branches/philikon-aq/lib/python/Products/Five/browser/providerexpression.py
===================================================================
--- Zope/branches/philikon-aq/lib/python/Products/Five/browser/providerexpression.py 2007-07-29 21:48:55 UTC (rev 78474)
+++ Zope/branches/philikon-aq/lib/python/Products/Five/browser/providerexpression.py 2007-07-29 22:15:48 UTC (rev 78475)
@@ -13,14 +13,10 @@
##############################################################################
"""Provider expression.
-$Id$
+This module solely exists for backwards-compatibility. Please import
+TALESProviderExpression from zope.contentprovider.tales.
"""
-from zope.contentprovider import interfaces as cp_interfaces
-from zope.contentprovider.tales import TALESProviderExpression
-from zope.interface import implements
-class Z2ProviderExpression(TALESProviderExpression):
- """This legacy provider was needed before to add acquisition wrappers to
- the providers in order for security to work."""
-
- implements(cp_interfaces.ITALESProviderExpression)
+# BBB
+from zope.contentprovider.tales import TALESProviderExpression \
+ as Z2ProviderExpression
Modified: Zope/branches/philikon-aq/lib/python/Products/PageTemplates/Expressions.py
===================================================================
--- Zope/branches/philikon-aq/lib/python/Products/PageTemplates/Expressions.py 2007-07-29 21:48:55 UTC (rev 78474)
+++ Zope/branches/philikon-aq/lib/python/Products/PageTemplates/Expressions.py 2007-07-29 22:15:48 UTC (rev 78475)
@@ -30,6 +30,7 @@
from zope.traversing.interfaces import ITraversable
from zope.traversing.adapters import traversePathElement
from zope.proxy import removeAllProxies
+from zope.contentprovider.tales import TALESProviderExpression
import zope.app.pagetemplate.engine
import OFS.interfaces
@@ -37,7 +38,6 @@
from Acquisition import aq_base
from zExceptions import NotFound, Unauthorized
-from Products.Five.browser.providerexpression import Z2ProviderExpression
from Products.PageTemplates import ZRPythonExpr
from Products.PageTemplates.DeferExpr import LazyExpr
from Products.PageTemplates.GlobalTranslationService import getGlobalTranslationService
@@ -345,7 +345,7 @@
e.registerType('not', NotExpr)
e.registerType('defer', DeferExpr)
e.registerType('lazy', LazyExpr)
- e.registerType('provider', Z2ProviderExpression)
+ e.registerType('provider', TALESProviderExpression)
e.registerBaseName('modules', SecureModuleImporter)
return e
More information about the Zope-Checkins
mailing list