mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-08-21 18:09:20 +00:00
ALF-12253: Incorrect path is generated if folder with name "webdav" is created
- Pointless servletPath argument removed from WebDAVHelper.getNodeForPath() - Analysis by Vadim confirms it's not needed and results in mis-handling of root folders called alfresco or webdav git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@46201 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (C) 2005-2010 Alfresco Software Limited.
|
||||
* Copyright (C) 2005-2013 Alfresco Software Limited.
|
||||
*
|
||||
* This file is part of Alfresco
|
||||
*
|
||||
@@ -63,7 +63,6 @@ public class MoveMethod extends HierarchicalMethod
|
||||
protected final void executeImpl() throws WebDAVServerException, Exception
|
||||
{
|
||||
NodeRef rootNodeRef = getRootNodeRef();
|
||||
String servletPath = getServletPath();
|
||||
// Debug
|
||||
if (logger.isDebugEnabled())
|
||||
{
|
||||
@@ -75,14 +74,14 @@ public class MoveMethod extends HierarchicalMethod
|
||||
FileInfo sourceInfo = null;
|
||||
try
|
||||
{
|
||||
sourceInfo = getDAVHelper().getNodeForPath(rootNodeRef, sourcePath, servletPath);
|
||||
sourceInfo = getDAVHelper().getNodeForPath(rootNodeRef, sourcePath);
|
||||
}
|
||||
catch (FileNotFoundException e)
|
||||
{
|
||||
throw new WebDAVServerException(HttpServletResponse.SC_NOT_FOUND);
|
||||
}
|
||||
|
||||
FileInfo sourceParentInfo = getDAVHelper().getParentNodeForPath(rootNodeRef, sourcePath, servletPath);
|
||||
FileInfo sourceParentInfo = getDAVHelper().getParentNodeForPath(rootNodeRef, sourcePath);
|
||||
|
||||
// the destination parent must exist
|
||||
String destPath = getDestinationPath();
|
||||
@@ -93,7 +92,7 @@ public class MoveMethod extends HierarchicalMethod
|
||||
{
|
||||
destPath = destPath.substring(0, destPath.length() - 1);
|
||||
}
|
||||
destParentInfo = getDAVHelper().getParentNodeForPath(rootNodeRef, destPath, servletPath);
|
||||
destParentInfo = getDAVHelper().getParentNodeForPath(rootNodeRef, destPath);
|
||||
}
|
||||
catch (FileNotFoundException e)
|
||||
{
|
||||
@@ -109,7 +108,7 @@ public class MoveMethod extends HierarchicalMethod
|
||||
boolean destExists = false;
|
||||
try
|
||||
{
|
||||
destInfo = getDAVHelper().getNodeForPath(rootNodeRef, destPath, servletPath);
|
||||
destInfo = getDAVHelper().getNodeForPath(rootNodeRef, destPath);
|
||||
if (!destInfo.getNodeRef().equals(sourceInfo.getNodeRef()))
|
||||
{
|
||||
// ALF-7079 fix, if destInfo is a hidden shuffle target then pretend it's not there
|
||||
|
Reference in New Issue
Block a user