Commit e134f69d authored by Florent Guillaume's avatar Florent Guillaume

Use isinstance, like the C implementation.

parent 621659c5
...@@ -317,9 +317,8 @@ class ZopeSecurityPolicy: ...@@ -317,9 +317,8 @@ class ZopeSecurityPolicy:
None) None)
if p is not None: if p is not None:
tp = p.__class__ if not isinstance(p, int): # catches bool too
if tp is not int and tp is not bool: if isinstance(p, dict):
if tp is dict:
if isinstance(name, basestring): if isinstance(name, basestring):
p = p.get(name) p = p.get(name)
else: else:
......
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