Shun Miyazawa 3 سال پیش
والد
کامیت
12d2a0e1d8
1فایلهای تغییر یافته به همراه3 افزوده شده و 1 حذف شده
  1. 3 1
      packages/app/src/components/PageRenameModal.tsx

+ 3 - 1
packages/app/src/components/PageRenameModal.tsx

@@ -127,7 +127,9 @@ const PageRenameModal = (): JSX.Element => {
     try {
       const res = await apiv3Get<{ existPaths: string[]}>('/page/exist-paths', { fromPath, toPath });
       const { existPaths } = res.data;
-      setCanRename(true);
+      if (existPaths.length === 0) {
+        setCanRename(true);
+      }
       setExistingPaths(existPaths);
     }
     catch (err) {