Просмотр исходного кода

fixed bug in checkIfTemplatesExist

sou 7 лет назад
Родитель
Сommit
6f2fae0304
1 измененных файлов с 1 добавлено и 1 удалено
  1. 1 1
      lib/models/page.js

+ 1 - 1
lib/models/page.js

@@ -541,7 +541,7 @@ module.exports = function(crowi) {
       .find({path: {$in: regexpList}})
       .then(templates => {
         templateInfo.childrenTemplateExists = (assignTemplateByType(templates, path, '_') ? true : false);
-        templateInfo.decendantsTemplateExists = (assignDecendantsTemplate(templates, path) ? true : false);
+        templateInfo.decendantsTemplateExists = (assignTemplateByType(templates, path, '__') ? true : false);
 
         return templateInfo;
       });