Skip to content

Commit 5368f4a

Browse files
Merge pull request #61842 from nextcloud/backport/61841/stable34
[stable34] fix(Sharing): Don't break cache entry by setting path to null
2 parents b79f667 + 02073fd commit 5368f4a

1 file changed

Lines changed: 5 additions & 1 deletion

File tree

apps/files_sharing/lib/Cache.php

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -134,7 +134,11 @@ public function moveFromCache(ICache $sourceCache, $sourcePath, $targetPath) {
134134
protected function formatCacheEntry($entry, $path = null) {
135135
if (is_null($path)) {
136136
$path = $entry['path'] ?? '';
137-
$entry['path'] = $this->getJailedPath($path);
137+
$jailedPath = $this->getJailedPath($path);
138+
if ($jailedPath === null) {
139+
return false;
140+
}
141+
$entry['path'] = $jailedPath;
138142
} else {
139143
$entry['path'] = $path;
140144
}

0 commit comments

Comments
 (0)