From: Julius Härtl Date: Mon, 7 Sep 2020 15:35:29 +0000 (+0200) Subject: Transfer shares if no path provided X-Git-Tag: v20.0.0beta4~32^2 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=aa04a26c68f977288782eec32f08ce8f43875961;p=nextcloud-server.git Transfer shares if no path provided Signed-off-by: Julius Härtl --- diff --git a/apps/files/lib/Service/OwnershipTransferService.php b/apps/files/lib/Service/OwnershipTransferService.php index 9f3e530478d..1fe9f037d0c 100644 --- a/apps/files/lib/Service/OwnershipTransferService.php +++ b/apps/files/lib/Service/OwnershipTransferService.php @@ -246,7 +246,7 @@ class OwnershipTransferService { private function collectUsersShares(string $sourceUid, OutputInterface $output, View $view, - ?string $path = null): array { + string $path): array { $output->writeln("Collecting all share information for files and folders of $sourceUid ..."); $shares = []; @@ -259,7 +259,7 @@ class OwnershipTransferService { if (empty($sharePage)) { break; } - if ($path !== null) { + if ($path !== "$sourceUid/files") { $sharePage = array_filter($sharePage, function (IShare $share) use ($view, $path) { try { $relativePath = $view->getPath($share->getNodeId());