mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-08-07 17:49:17 +00:00
Build fix for NPE in QueryTest
java.lang.NullPointerException at org.alfresco.opencmis.mapping.AllowedChildObjectTypeIdsProperty.getValueInternal(AllowedChildObjectTypeIdsProperty.java:56) at org.alfresco.opencmis.mapping.AbstractProperty.getValue(AbstractProperty.java:102) at org.alfresco.opencmis.search.CmisFunctionEvaluationContext.getProperty(CmisFunctionEvaluationContext.java:215) at org.alfresco.repo.search.impl.querymodel.impl.BasePropertyArgument.getValue(BasePropertyArgument.java:75) at org.alfresco.repo.search.impl.querymodel.impl.functions.PropertyAccessor.getValue(PropertyAccessor.java:74) at org.alfresco.opencmis.search.CMISResultSetRow.getValue(CMISResultSetRow.java:174) at org.alfresco.opencmis.search.QueryTest.testBasicAllFolderColumns(QueryTest.java:3531) git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@32073 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -53,6 +53,11 @@ public class AllowedChildObjectTypeIdsProperty extends AbstractProperty
|
||||
@Override
|
||||
public Serializable getValueInternal(CMISNodeInfo nodeInfo)
|
||||
{
|
||||
if(nodeInfo.getType() == null)
|
||||
{
|
||||
return (Serializable) Collections.emptyList();
|
||||
}
|
||||
|
||||
TypeDefinition type = getServiceRegistry().getDictionaryService()
|
||||
.getType(nodeInfo.getType().getAlfrescoClass());
|
||||
if ((type != null) && (type.getChildAssociations() != null) && (!type.getChildAssociations().isEmpty()))
|
||||
|
Reference in New Issue
Block a user