diff --git a/product/ERP5Security/ERP5UserFactory.py b/product/ERP5Security/ERP5UserFactory.py index aa00fc47b47be62bf7caaf52c99e552233686d7e..f06aeb832b67f6a1dc2a55d9b8b42e12b5fbc1be 100644 --- a/product/ERP5Security/ERP5UserFactory.py +++ b/product/ERP5Security/ERP5UserFactory.py @@ -157,8 +157,8 @@ class ERP5User(PropertiedUser): return 0 # patch by Klaus for LocalRole blocking - if getattr(object, '_getAcquireLocalRoles', None) is not None: - if not object._getAcquireLocalRoles(): + if getattr(inner_obj, '_getAcquireLocalRoles', None) is not None: + if not inner_obj._getAcquireLocalRoles(): break inner = aq_inner( inner_obj )