[ZPT] CVS: Packages/Products/PageTemplates (Products/DC/PageTemplates) - Expressions.py:1.12
evan@serenade.digicool.com
evan@serenade.digicool.com
Fri, 18 May 2001 14:10:17 -0400
Update of /cvs-repository/Packages/Products/PageTemplates
In directory serenade:/home/evan/Zope/pt/lib/python/Products/PageTemplates
Modified Files:
Expressions.py
Log Message:
Fix validation when calling DTML
--- Updated File Expressions.py in package Packages/Products/PageTemplates --
--- Expressions.py 2001/05/11 23:44:51 1.11
+++ Expressions.py 2001/05/18 18:10:16 1.12
@@ -118,9 +118,11 @@
if sys.modules.has_key('Zope'):
from AccessControl import getSecurityManager
from DocumentTemplate.DT_Util import TemplateDict, InstanceDict
+ def validate(accessed, container, name, value, dummy):
+ return getSecurityManager().validate(accessed, container, name, value)
def call_with_ns(f, ns, arg=1):
td = TemplateDict()
- td.validate = getSecurityManager().validate
+ td.validate = validate
td.this = None
td._push(ns['request'])
td._push(InstanceDict(ns['here'], td))