ALF-11817: removed change since it breaks tests and essentially duplicates code a few lines above.

git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@38650 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Matt Ward
2012-07-02 15:47:02 +00:00
parent be613bac53
commit cd8d902f8b

View File

@@ -90,33 +90,6 @@ public class UnlockMethod extends WebDAVMethod
logger.warn("Failed to parse If header: " + strLockTokenHeader);
}
}
// ALF-11817 If the header Lock-Token is incorrect (without < and >).
else
{
// Build the lock token.
FileInfo lockNodeInfo = null;
String userName = null;
try
{
userName = getDAVHelper().getAuthenticationService().getCurrentUserName();
lockNodeInfo = getNodeForPath(getRootNodeRef(), getPath(), getServletPath());
}
catch (AuthenticationException ex)
{
throw new WebDAVServerException(HttpServletResponse.SC_UNAUTHORIZED);
}
catch (FileNotFoundException e)
{
throw new WebDAVServerException(HttpServletResponse.SC_NOT_FOUND);
}
String buildLockToken = WebDAV.makeLockToken(lockNodeInfo.getNodeRef(), userName);
// End build.
if (strLockTokenHeader.equalsIgnoreCase(buildLockToken))
{
m_strLockToken = strLockTokenHeader;
}
}
}
// If there is no token this is a bad request so send an error back
if (m_strLockToken == null)