|
@@ -548,6 +548,7 @@ module.exports = function(crowi) {
|
|
|
childrenTemplateExists: false,
|
|
childrenTemplateExists: false,
|
|
|
decendantsTemplateExists: false,
|
|
decendantsTemplateExists: false,
|
|
|
};
|
|
};
|
|
|
|
|
+ console.log('regexp', regexpList)
|
|
|
|
|
|
|
|
return Page
|
|
return Page
|
|
|
.find({path: {$in: regexpList}})
|
|
.find({path: {$in: regexpList}})
|
|
@@ -582,11 +583,12 @@ module.exports = function(crowi) {
|
|
|
};
|
|
};
|
|
|
|
|
|
|
|
const generatePathsOnTree = (path, pathList) => {
|
|
const generatePathsOnTree = (path, pathList) => {
|
|
|
|
|
+ pathList.push(path);
|
|
|
|
|
+
|
|
|
if (path === '') {
|
|
if (path === '') {
|
|
|
return pathList;
|
|
return pathList;
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
- pathList.push(path);
|
|
|
|
|
const newPath = cutOffLastSlash(path);
|
|
const newPath = cutOffLastSlash(path);
|
|
|
|
|
|
|
|
return generatePathsOnTree(newPath, pathList);
|
|
return generatePathsOnTree(newPath, pathList);
|