Skip to content

Commit

Permalink
fix: Update the common path to include parent
Browse files Browse the repository at this point in the history
  • Loading branch information
andymac4182 committed Apr 28, 2023
1 parent 3bb44dd commit 076effd
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion packages/lib/src/TreeLocal.ts
Expand Up @@ -91,7 +91,13 @@ const processNode = (commonPath: string, node: LocalAdfFileTreeNode) => {
}
}

node.children.forEach((childNode) => processNode(commonPath, childNode));
const childCommonPath = path.parse(
node?.file?.absoluteFilePath ?? commonPath
).dir;

node.children.forEach((childNode) =>
processNode(childCommonPath, childNode)
);
};

export const createFolderStructure = (
Expand Down

0 comments on commit 076effd

Please sign in to comment.