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

134050 rmunteanu: REPO-1752: Create person with long id returns 500
      - Changed validation message.


git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@137335 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Andrei Rebegea
2017-06-14 16:56:20 +00:00
parent a3fcd7a5b3
commit 986b7ae73d

View File

@@ -86,6 +86,7 @@ public class PeopleImpl implements People
NamespaceService.CONTENT_MODEL_1_0_URI);
private static final List<QName> EXCLUDED_ASPECTS = Arrays.asList();
private static final List<QName> EXCLUDED_PROPS = Arrays.asList();
private static final int USERNAME_MAXLENGTH = 100;
protected Nodes nodes;
protected Sites sites;
@@ -523,7 +524,7 @@ public class PeopleImpl implements People
{
if (username.length() > 100)
{
throw new InvalidArgumentException("Username is too long.");
throw new InvalidArgumentException("Username exceeds max length of " + USERNAME_MAXLENGTH + " characters.");
}
if (username.indexOf('/') != -1)