diff --git a/bl-kernel/pages.class.php b/bl-kernel/pages.class.php index e3bc3b0b..0da47ab0 100644 --- a/bl-kernel/pages.class.php +++ b/bl-kernel/pages.class.php @@ -322,8 +322,10 @@ class Pages extends dbJSON { } // Delete page images directory; The function already check if exists the directory - if (Filesystem::deleteRecursive(PATH_UPLOADS_PAGES.$key) === false) { - Log::set(__METHOD__.LOG_SEP.'Directory with images not found '.PATH_UPLOADS_PAGES.$key); + if (($uuid = $this->getUUID($key))) { + if (Filesystem::deleteRecursive(PATH_UPLOADS_PAGES.$uuid) === false) { + Log::set(__METHOD__.LOG_SEP.'Directory with images not found '.PATH_UPLOADS_PAGES.$uuid); + } } // Remove from database