You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@jackrabbit.apache.org by GitBox <gi...@apache.org> on 2021/07/01 12:25:25 UTC

[GitHub] [jackrabbit-filevault] DominikSuess commented on a change in pull request #155: JCRVLT-544 never create intermediate nodes of type nt:base or

DominikSuess commented on a change in pull request #155:
URL: https://github.com/apache/jackrabbit-filevault/pull/155#discussion_r662242550



##########
File path: vault-core/src/main/java/org/apache/jackrabbit/vault/fs/impl/io/FolderArtifactHandler.java
##########
@@ -62,6 +70,18 @@ public void setNodeType(String nodeType) {
         this.nodeType = nodeType;
     }
 
+    private Node createIntermediateNode(Node parent, String intermediateNodeName) throws RepositoryException {
+        // preferably use default (=primary) node type for intermediate nodes
+        NodeType primaryNodeType = parent.getPrimaryNodeType();
+        final Node node;
+        if (!DISALLOWED_PRIMARY_NODE_TYPE_NAMES.contains(primaryNodeType.getName()) && 

Review comment:
       @kwin  - this doesn't solve the issue at hand - it is not the primaryType of the parent that is the problem but the default nodetype - therefore the default nodetype would need to be detected and compared instead (IIUC thats part of the NodeDefinitions that can be obtained via getChildNodeDefinitions())




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@jackrabbit.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org