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

127555 jkaabimofrad: Merged API-STRIKES-BACK (5.2.0) to HEAD (5.2)
      125601 jvonka: RA-779: Sites API - create site
      - additional tests (site description & also max lengths for id, title & description)
      - fix site id validation (repeating valid chars)


git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/BRANCHES/DEV/5.2.N/root@127649 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Alan Davis
2016-06-03 14:03:37 +00:00
parent 493b7e76e6
commit a7d99dded0
3 changed files with 42 additions and 4 deletions

View File

@@ -955,7 +955,7 @@ public class SitesImpl implements Sites
}
else
{
if (! siteId.matches("[^"+SITE_ID_VALID_CHARS_PARTIAL_REGEX+"]"))
if (! siteId.matches("^["+SITE_ID_VALID_CHARS_PARTIAL_REGEX+"]+"))
{
throw new InvalidArgumentException("Invalid site id - should consist of alphanumeric/dash characters");
}