private List<ExplorerNode> pruneNodePath(final List<ExplorerNode> rootPath,
                                             final List<ExplorerNode> nodePath) {
        List<ExplorerNode> resultPath = nodePath;

        if (rootPath != null) {
            List<String> rootUuids = rootPath.stream()
                    .map(ExplorerNode::getUuid)
                    .toList();
            List<String> nodeUuids = nodePath.stream()
                    .map(ExplorerNode::getUuid)
                    .limit(rootPath.size())
                    .toList();
            if (rootUuids.equals(nodeUuids)) {
                resultPath = nodePath.subList(rootPath.size(), nodePath.size());
            } else {
                LOGGER.warn("Node path '{}' does not start with the root path '{}'", nodePath, rootPath);
            }
        }

        return resultPath;
    }
Prunes the node path for GitRepo exports. Removes everything in the rootPath
from the nodePath if the rootPath matches the start of the nodePath.
@param rootPath Can be null, in which case this function just returns nodePath.
                Otherwise, the list of items to prune from the start of nodePath.
@param nodePath The node path to prune.
@return The pruned nodePath.
stroom-importexport/stroom-importexport-impl/src/main/java/stroom/importexport/impl/ImportExportSerializerImpl.java