don't move empty folders to the trash bin

remotes/origin/stable6
Björn Schießle 12 years ago
parent bf668eb14f
commit 96e175ffbf
  1. 5
      apps/files_trashbin/lib/trash.php

@ -72,6 +72,11 @@ class Trashbin {
$mime = $view->getMimeType('files' . $file_path);
if ($view->is_dir('files' . $file_path)) {
$dirContent = $view->getDirectoryContent('files' . $file_path);
// no need to move empty folders to the trash bin
if (empty($dirContent)) {
return true;
}
$type = 'dir';
} else {
$type = 'file';

Loading…
Cancel
Save