Fix for tenant-specific WebDAV (fix for r6634)

git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@6666 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Jan Vonka
2007-09-03 14:24:54 +00:00
parent d645991fae
commit 38c103e17b

View File

@@ -221,7 +221,7 @@ public class WebDAVServlet extends HttpServlet
// Create the handler method // Create the handler method
method = (WebDAVMethod) methodClass.newInstance(); method = (WebDAVMethod) methodClass.newInstance();
NodeRef rootNodeRef = null; NodeRef rootNodeRef = m_rootNodeRef;
if (m_tenantService.isEnabled()) if (m_tenantService.isEnabled())
{ {
WebApplicationContext context = WebApplicationContextUtils.getRequiredWebApplicationContext(getServletContext()); WebApplicationContext context = WebApplicationContextUtils.getRequiredWebApplicationContext(getServletContext());
@@ -229,12 +229,9 @@ public class WebDAVServlet extends HttpServlet
SearchService searchService = (SearchService) context.getBean("SearchService"); SearchService searchService = (SearchService) context.getBean("SearchService");
NamespaceService namespaceService = (NamespaceService) context.getBean("NamespaceService"); NamespaceService namespaceService = (NamespaceService) context.getBean("NamespaceService");
// note: rootNodeRef is required (for storeRef part)
rootNodeRef = m_tenantService.getRootNode(nodeService, searchService, namespaceService, m_rootPath, rootNodeRef); rootNodeRef = m_tenantService.getRootNode(nodeService, searchService, namespaceService, m_rootPath, rootNodeRef);
} }
else
{
rootNodeRef = m_rootNodeRef;
}
method.setDetails(request, response, m_davHelper, rootNodeRef); method.setDetails(request, response, m_davHelper, rootNodeRef);
} }