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

134045 cturlica: REPO-1684: We should not return properties that are empty
      - Empty (zero length) string values are considered to be null values, and will be represented the same as null values (i.e. by non-existence of the property).


git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@137334 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Andrei Rebegea
2017-06-14 16:56:13 +00:00
parent 7b013ec1c5
commit a3fcd7a5b3
4 changed files with 63 additions and 0 deletions

View File

@@ -1197,6 +1197,15 @@ public class NodesImpl implements Nodes
{
value = Node.lookupUserInfo((String)value, mapUserInfo, sr.getPersonService());
}
// Empty (zero length) string values are considered to be
// null values, and will be represented the same as null
// values (i.e. by non-existence of the property).
if (value != null && value instanceof String && ((String) value).isEmpty())
{
continue;
}
props.put(qName.toPrefixString(namespaceService), value);
}
}