mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-07-31 17:39:05 +00:00
Merge pull request #2446 from Alfresco/feature/mkinas-ACS-5506-exception-fix
[ACS-5506] Fix string to node ref cast exception
This commit is contained in:
@@ -147,7 +147,7 @@ public class GroupsImpl implements Groups
|
|||||||
}
|
}
|
||||||
|
|
||||||
Map<QName, Serializable> props = new HashMap<>();
|
Map<QName, Serializable> props = new HashMap<>();
|
||||||
if (StringUtils.isNotEmpty(group.getDescription()))
|
if (group.getDescription() != null)
|
||||||
{
|
{
|
||||||
props.put(ContentModel.PROP_DESCRIPTION, group.getDescription());
|
props.put(ContentModel.PROP_DESCRIPTION, group.getDescription());
|
||||||
}
|
}
|
||||||
@@ -170,7 +170,7 @@ public class GroupsImpl implements Groups
|
|||||||
|
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
if (StringUtils.isNotEmpty(group.getDescription()))
|
if (group.getDescription() != null)
|
||||||
{
|
{
|
||||||
authorityService.setAuthorityDisplayNameAndDescription(groupId, group.getDisplayName(), group.getDescription());
|
authorityService.setAuthorityDisplayNameAndDescription(groupId, group.getDisplayName(), group.getDescription());
|
||||||
}
|
}
|
||||||
|
@@ -424,6 +424,11 @@ public class ACLEntryAfterInvocationProvider implements AfterInvocationProvider,
|
|||||||
@SuppressWarnings("rawtypes")
|
@SuppressWarnings("rawtypes")
|
||||||
private Pair decide(Authentication authentication, Object object, ConfigAttributeDefinition config, Pair returnedObject) throws AccessDeniedException
|
private Pair decide(Authentication authentication, Object object, ConfigAttributeDefinition config, Pair returnedObject) throws AccessDeniedException
|
||||||
{
|
{
|
||||||
|
if (returnedObject.getSecond() != null && !NodeRef.class.isAssignableFrom(returnedObject.getSecond().getClass()))
|
||||||
|
{
|
||||||
|
return returnedObject;
|
||||||
|
}
|
||||||
|
|
||||||
NodeRef nodeRef = (NodeRef) returnedObject.getSecond();
|
NodeRef nodeRef = (NodeRef) returnedObject.getSecond();
|
||||||
decide(authentication, object, config, nodeRef);
|
decide(authentication, object, config, nodeRef);
|
||||||
// the noderef was allowed
|
// the noderef was allowed
|
||||||
|
Reference in New Issue
Block a user