Commit 8eaceae0 authored by Rafael Monnerat's avatar Rafael Monnerat

erp5_core: rely on ERP5User property sheet to identify users

parent 40b116a0
Pipeline #38618 failed with stage
in 0 seconds
......@@ -175,7 +175,11 @@ def asSecurityGroupIdSet(category_dict, key_sort=sorted):
except KeyError:
continue
for category_value, is_child_category in category_list:
if category_value.getPortalType() == 'Person':
if 'ERP5User' in getattr(
category_value.getTypeInfo(),
'getTypePropertySheetList',
lambda: ()
)():
user_name = category_value.Person_getUserId()
if user_name is not None:
user_list.append(user_name)
......
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