Explorar o código

remove rename pageOperation

yohei0125 %!s(int64=4) %!d(string=hai) anos
pai
achega
7058f812f6
Modificáronse 1 ficheiros con 2 adicións e 2 borrados
  1. 2 2
      packages/app/src/server/service/page-operation.ts

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

@@ -1,6 +1,6 @@
 import { pagePathUtils } from '@growi/core';
 
-import PageOperation from '~/server/models/page-operation';
+import PageOperation, { PageActionType } from '~/server/models/page-operation';
 
 const { isEitherOfPathAreaOverlap, isPathAreaOverlap, isTrashPage } = pagePathUtils;
 
@@ -14,7 +14,7 @@ class PageOperationService {
 
   // TODO: Remove this code when resuming feature is implemented
   async init():Promise<void> {
-    await PageOperation.deleteMany({});
+    await PageOperation.deleteMany({ actionType: { $ne: PageActionType.Rename } });
   }
 
   /**