Commit 44f0e9ad authored by Andreas Jung's avatar Andreas Jung

Setting proxy roles on DTMLMethod/Documents has been broken

due to changes in the security machinery
parent efb60e83
......@@ -8,6 +8,8 @@ Zope Changes
Bugs Fixed
- Setting proxy roles on DTMLMethods and Documents has been broken
- Collector #99: items(), keys() and values() methods
of IIBucket objects has been broken when called with
min/max parameters.
......
......@@ -12,7 +12,7 @@
##############################################################################
"""DTML Method objects."""
__version__='$Revision: 1.72 $'[11:-2]
__version__='$Revision: 1.73 $'[11:-2]
import History
from Globals import HTML, DTMLFile, MessageDialog
......@@ -278,7 +278,7 @@ class DTMLMethod(RestrictedDTML, HTML, Acquisition.Implicit, RoleManager,
if roles is None: roles=self._proxy_roles
if not roles: return
user=u=getSecurityManager().getUser()
user=user.hasRole
user=user.allowed
for r in roles:
if r and not user(self, (r,)):
user=None
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment