Răsfoiți Sursa

fix empty trash bug

yuken 3 ani în urmă
părinte
comite
f56aa6861e
1 a modificat fișierele cu 1 adăugiri și 1 ștergeri
  1. 1 1
      packages/app/src/server/routes/apiv3/pages.js

+ 1 - 1
packages/app/src/server/routes/apiv3/pages.js

@@ -594,7 +594,7 @@ module.exports = (crowi) => {
   router.delete('/empty-trash', accessTokenParser, loginRequired, csrf, apiV3FormValidator, async(req, res) => {
     const options = {};
 
-    const pagesInTrash = await Page.findChildrenByParentPathOrIdAndViewer('/trash', req.user);
+    const pagesInTrash = await crowi.pageService.findChildrenByParentPathOrIdAndViewer('/trash', req.user);
 
     const deletablePages = crowi.pageService.filterPagesByCanDeleteCompletely(pagesInTrash, req.user, true);