Taichi Masuyama 3 лет назад
Родитель
Сommit
e8a7b22468
1 измененных файлов с 2 добавлено и 1 удалено
  1. 2 1
      packages/app/src/server/service/page-grant.ts

+ 2 - 1
packages/app/src/server/service/page-grant.ts

@@ -560,7 +560,8 @@ class PageGrantService {
       }
       const UserGroupRelation = mongoose.model('UserGroupRelation') as any; // TODO: Typescriptize model
       const userIds = await UserGroupRelation.findAllUserIdsForUserGroup(grantUserGroupId);
-      const childrenOrItselfGroupIds = await UserGroup.findGroupsWithDescendantsById(grantUserGroupId).map(d => d._id);
+      const childrenOrItselfGroups = await UserGroup.findGroupsWithDescendantsById(grantUserGroupId);
+      const childrenOrItselfGroupIds = childrenOrItselfGroups.map(d => d._id);
 
       updateGrantInfo = {
         grant: PageGrant.GRANT_USER_GROUP,