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 ...@@ -8,6 +8,8 @@ Zope Changes
Bugs Fixed Bugs Fixed
- Setting proxy roles on DTMLMethods and Documents has been broken
- Collector #99: items(), keys() and values() methods - Collector #99: items(), keys() and values() methods
of IIBucket objects has been broken when called with of IIBucket objects has been broken when called with
min/max parameters. min/max parameters.
......
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
############################################################################## ##############################################################################
"""DTML Method objects.""" """DTML Method objects."""
__version__='$Revision: 1.72 $'[11:-2] __version__='$Revision: 1.73 $'[11:-2]
import History import History
from Globals import HTML, DTMLFile, MessageDialog from Globals import HTML, DTMLFile, MessageDialog
...@@ -278,7 +278,7 @@ class DTMLMethod(RestrictedDTML, HTML, Acquisition.Implicit, RoleManager, ...@@ -278,7 +278,7 @@ class DTMLMethod(RestrictedDTML, HTML, Acquisition.Implicit, RoleManager,
if roles is None: roles=self._proxy_roles if roles is None: roles=self._proxy_roles
if not roles: return if not roles: return
user=u=getSecurityManager().getUser() user=u=getSecurityManager().getUser()
user=user.hasRole user=user.allowed
for r in roles: for r in roles:
if r and not user(self, (r,)): if r and not user(self, (r,)):
user=None 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