Commit 360fd83e authored by Hanno Schlichting's avatar Hanno Schlichting

Merged c105405 from 2.12 branch

parent 8960ead6
......@@ -77,7 +77,10 @@ def InitializeClass(self):
pr = PermissionRole(pname)
for mname in mnames:
setattr(self, mname+'__roles__', pr)
if mname and not hasattr(self, mname):
if (mname and mname not in ('context', 'request') and
not hasattr(self, mname)):
# don't complain about context or request, as they are
# frequently not available as class attributes
logging.getLogger("Init").warning(
"Class %s.%s has a security declaration for "
"nonexistent method %r", self.__module__,
......
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