Merge pull request #5836 from nextcloud/preview_update
Empty search no longer works
This commit is contained in:
commit
63676d3b24
1 changed files with 7 additions and 1 deletions
|
@ -77,10 +77,16 @@ class Watcher {
|
|||
}
|
||||
|
||||
/** @var Folder $node */
|
||||
$nodes = $node->search('');
|
||||
$this->deleteFolder($node);
|
||||
}
|
||||
|
||||
private function deleteFolder(Folder $folder) {
|
||||
$nodes = $folder->getDirectoryListing();
|
||||
foreach ($nodes as $node) {
|
||||
if ($node instanceof File) {
|
||||
$this->toDelete[] = $node->getId();
|
||||
} else if ($node instanceof Folder) {
|
||||
$this->deleteFolder($node);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue