Skip to content

Commit 09b7e8b

Browse files
authored
Merge pull request #56972 from nextcloud/backport/56758/stable29
2 parents 418e422 + 063d0ff commit 09b7e8b

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

lib/private/Files/View.php

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1909,7 +1909,15 @@ private function targetIsNotShared(string $user, string $targetPath): bool {
19091909
}, $providers));
19101910

19111911
foreach ($shares as $share) {
1912-
$sharedPath = $share->getNode()->getPath();
1912+
try {
1913+
$sharedPath = $share->getNode()->getPath();
1914+
} catch (NotFoundException $e) {
1915+
// node is not found, ignoring
1916+
$this->logger->debug(
1917+
'Could not find the node linked to a share',
1918+
['app' => 'files', 'exception' => $e]);
1919+
continue;
1920+
}
19131921
if ($targetPath === $sharedPath || str_starts_with($targetPath, $sharedPath . '/')) {
19141922
$this->logger->debug(
19151923
'It is not allowed to move one mount point into a shared folder',

0 commit comments

Comments
 (0)