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

modify the conditional branching before executing the process

WNomunomu 1 год назад
Родитель
Сommit
af77550c4f
1 измененных файлов с 1 добавлено и 1 удалено
  1. 1 1
      apps/app/src/server/service/page/index.ts

+ 1 - 1
apps/app/src/server/service/page/index.ts

@@ -4109,7 +4109,7 @@ class PageService implements IPageService {
     }
     }
 
 
     // 3. Update scopes for descendants
     // 3. Update scopes for descendants
-    if (options.overwriteScopesOfDescendants) {
+    if (options.overwriteScopesOfDescendants && shouldBeOnTree) {
       await this.applyScopesToDescendantsWithStream(currentPage, user);
       await this.applyScopesToDescendantsWithStream(currentPage, user);
     }
     }