Commit fdea454c authored by Sebastien Robin's avatar Sebastien Robin

it is very important to take the user from the owner, if we take the current...

it is very important to take the user from the owner, if we take the current user logged in, then security definition will not be stable

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@7696 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent da845491
......@@ -273,6 +273,12 @@ class ERP5TypeInformation( FactoryTypeInformation, RoleProviderBase, Translation
"""
#FIXME We should check the type of the acl_users folder instead of
# checking which product is installed.
if user_name is None:
# First try to guess from the owner
try:
user_name = object.getOwnerInfo()['id']
except AttributeError:
pass
if user_name is None:
if ERP5UserManager is not None:
# We use id for roles in ERP5Security
......
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