public static function prepare_delete($args, $prefix = '') { $path = $args['path']; if (substr($path, 0, 1) === '/') { $path = substr($path, 1); } $view = new \OC\Files\View('/' . \OC_User::getUser() . '/' . $prefix); $info = $view->getFileInfo($path); \OC\Preview::$deleteFileMapper = array_merge(\OC\Preview::$deleteFileMapper, array(Files\Filesystem::normalizePath($view->getAbsolutePath($path)) => $info)); }