mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-08-14 17:58:59 +00:00
Merged HEAD (5.2) to 5.2.N (5.2.1)
126635 jkaabimofrad: Merged FILE-FOLDER-API (5.2.0) to HEAD (5.2) 126115 jvonka: RA-1028: Fix copy bug - if same parent & name (ie. nothing copied) then return 409 rather than 201 - see also SFS-554 git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/BRANCHES/DEV/5.2.N/root@126986 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -1907,7 +1907,13 @@ public class NodesImpl implements Nodes
|
||||
if (isCopy)
|
||||
{
|
||||
// copy
|
||||
return fileFolderService.copy(nodeRef, parentNodeRef, name);
|
||||
FileInfo newFileInfo = fileFolderService.copy(nodeRef, parentNodeRef, name);
|
||||
if (newFileInfo.getNodeRef().equals(nodeRef))
|
||||
{
|
||||
// copy did not happen - eg. same parent folder and name (name can be null or same)
|
||||
throw new FileExistsException(nodeRef, "");
|
||||
}
|
||||
return newFileInfo;
|
||||
}
|
||||
else
|
||||
{
|
||||
|
Reference in New Issue
Block a user