kaori 4 лет назад
Родитель
Сommit
e2640d6945
1 измененных файлов с 1 добавлено и 4 удалено
  1. 1 4
      packages/app/src/components/Page/TrashPageAlert.jsx

+ 1 - 4
packages/app/src/components/Page/TrashPageAlert.jsx

@@ -7,7 +7,6 @@ import { UserPicture } from '@growi/ui';
 import { withUnstatedContainers } from '../UnstatedUtils';
 import { withUnstatedContainers } from '../UnstatedUtils';
 import AppContainer from '~/client/services/AppContainer';
 import AppContainer from '~/client/services/AppContainer';
 import PageContainer from '~/client/services/PageContainer';
 import PageContainer from '~/client/services/PageContainer';
-import { useSWRxPageChildren } from '~/stores/page-listing';
 import PutbackPageModal from '../PutbackPageModal';
 import PutbackPageModal from '../PutbackPageModal';
 import EmptyTrashModal from '../EmptyTrashModal';
 import EmptyTrashModal from '../EmptyTrashModal';
 
 
@@ -23,7 +22,6 @@ const TrashPageAlert = (props) => {
   const { data: shareLinkId } = useShareLinkId();
   const { data: shareLinkId } = useShareLinkId();
   const { data: pageInfo } = useSWRxPageInfo(pageId ?? null, shareLinkId);
   const { data: pageInfo } = useSWRxPageInfo(pageId ?? null, shareLinkId);
   const { data: updatedAt } = useCurrentUpdatedAt();
   const { data: updatedAt } = useCurrentUpdatedAt();
-  const { mutate: mutateChildren } = useSWRxPageChildren(path);
   const [isEmptyTrashModalShown, setIsEmptyTrashModalShown] = useState(false);
   const [isEmptyTrashModalShown, setIsEmptyTrashModalShown] = useState(false);
   const [isPutbackPageModalShown, setIsPutbackPageModalShown] = useState(false);
   const [isPutbackPageModalShown, setIsPutbackPageModalShown] = useState(false);
   const [isAbleToDeleteCompletely, setIsAbleToDeleteCompletely] = useState(false);
   const [isAbleToDeleteCompletely, setIsAbleToDeleteCompletely] = useState(false);
@@ -56,11 +54,10 @@ const TrashPageAlert = (props) => {
     if (typeof pathOrPathsToDelete !== 'string') {
     if (typeof pathOrPathsToDelete !== 'string') {
       return;
       return;
     }
     }
-    mutateChildren();
 
 
     const path = pathOrPathsToDelete;
     const path = pathOrPathsToDelete;
     window.location.href = path;
     window.location.href = path;
-  }, [mutateChildren]);
+  }, []);
 
 
   function openPageDeleteModalHandler() {
   function openPageDeleteModalHandler() {
     const pageToDelete = {
     const pageToDelete = {