Further subdue exception that contains no useful information and is prevelant during auditing.

git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/modules/recordsmanagement/BRANCHES/V2.3@97189 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Roy Wetherall
2015-02-17 04:34:45 +00:00
parent 83f5b5d74a
commit 4712fa05bb

View File

@@ -460,14 +460,12 @@ public class FilePlanServiceImpl extends ServiceBaseImpl
*/ */
private void getNodeRefPathRecursive(NodeRef nodeRef, Deque<NodeRef> nodeRefPath) private void getNodeRefPathRecursive(NodeRef nodeRef, Deque<NodeRef> nodeRefPath)
{ {
if (!isFilePlanComponent(nodeRef)) if (isFilePlanComponent(nodeRef))
{ {
throw new AlfrescoRuntimeException(I18NUtil.getMessage(MSG_INVALID_RM_NODE, ASPECT_FILE_PLAN_COMPONENT.toString()));
}
// Prepend it to the path // Prepend it to the path
nodeRefPath.addFirst(nodeRef); nodeRefPath.addFirst(nodeRef);
// Are we not at the root // Are we not at the root
if (!isFilePlan(nodeRef) && isFilePlanComponent(nodeRef)) if (!isFilePlan(nodeRef))
{ {
ChildAssociationRef assocRef = nodeService.getPrimaryParent(nodeRef); ChildAssociationRef assocRef = nodeService.getPrimaryParent(nodeRef);
if (assocRef == null) if (assocRef == null)
@@ -480,6 +478,7 @@ public class FilePlanServiceImpl extends ServiceBaseImpl
getNodeRefPathRecursive(nodeRef, nodeRefPath); getNodeRefPathRecursive(nodeRef, nodeRefPath);
} }
} }
}
/** /**
* @see org.alfresco.module.org_alfresco_module_rm.fileplan.FilePlanService#createRecordCategory(org.alfresco.service.cmr.repository.NodeRef, java.lang.String, org.alfresco.service.namespace.QName, java.util.Map) * @see org.alfresco.module.org_alfresco_module_rm.fileplan.FilePlanService#createRecordCategory(org.alfresco.service.cmr.repository.NodeRef, java.lang.String, org.alfresco.service.namespace.QName, java.util.Map)