Merged HEAD (5.2) to 5.2.N (5.2.1)

126535 jkaabimofrad: Merged FILE-FOLDER-API (5.2.0) to HEAD (5.2)
      123185 jvonka: RA-706, ACE-5113: Revese merge 123162 & 123163 (needs more thought, re: impact on existing tests etc)


git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/BRANCHES/DEV/5.2.N/root@126879 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Ancuta Morarasu
2016-05-11 12:03:25 +00:00
parent 9aeabb0398
commit 76971dbbf3
3 changed files with 38 additions and 90 deletions

View File

@@ -51,9 +51,7 @@ import org.alfresco.service.cmr.repository.NodeRef;
import org.alfresco.service.cmr.repository.NodeService;
import org.alfresco.service.cmr.repository.datatype.DefaultTypeConverter;
import org.alfresco.service.cmr.security.AuthenticationService;
import org.alfresco.service.cmr.security.NoSuchPersonException;
import org.alfresco.service.cmr.security.OwnableService;
import org.alfresco.service.cmr.security.PersonService;
import org.alfresco.service.namespace.QName;
import org.alfresco.util.EqualsHelper;
import org.alfresco.util.PropertyCheck;
@@ -78,7 +76,6 @@ public class OwnableServiceImpl implements
private TenantService tenantService;
private Set<String> storesToIgnorePolicies = Collections.emptySet();
private RenditionService renditionService;
private PersonService personService;
public OwnableServiceImpl()
{
@@ -130,11 +127,6 @@ public class OwnableServiceImpl implements
this.renditionService = renditionService;
}
public void setPersonService(PersonService personService)
{
this.personService = personService;
}
public void afterPropertiesSet() throws Exception
{
PropertyCheck.mandatory(this, "nodeService", nodeService);
@@ -142,7 +134,6 @@ public class OwnableServiceImpl implements
PropertyCheck.mandatory(this, "nodeOwnerCache", nodeOwnerCache);
PropertyCheck.mandatory(this, "policyComponent", policyComponent);
PropertyCheck.mandatory(this, "renditionService", renditionService);
PropertyCheck.mandatory(this, "personService", personService);
}
public void init()
@@ -287,25 +278,6 @@ public class OwnableServiceImpl implements
if (!EqualsHelper.nullSafeEquals(pb, pa))
{
if (pa != null)
{
String username = (String) pa;
NodeRef personNodeRef = null;
// validate that user authentication exists
if (authenticationService.authenticationExists(username))
{
// validate that person exists
// note: will attempt to create missing person, if allowed - may throw NoSuchPersonException
personNodeRef = personService.getPerson(username, true);
}
if (personNodeRef == null)
{
throw new NoSuchPersonException(username);
}
}
nodeOwnerCache.remove(nodeRef);
return;
}