Merge pull request #61844 from nextcloud/backport/61841/stable32

[stable32] fix(Sharing): Don't break cache entry by setting path to null
This commit is contained in:
Joas Schilling 2026-07-08 11:07:57 +02:00 committed by GitHub
commit 6b7872dbf2
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -124,7 +124,11 @@ class Cache extends CacheJail {
protected function formatCacheEntry($entry, $path = null) {
if (is_null($path)) {
$path = $entry['path'] ?? '';
$entry['path'] = $this->getJailedPath($path);
$jailedPath = $this->getJailedPath($path);
if ($jailedPath === null) {
return false;
}
$entry['path'] = $jailedPath;
} else {
$entry['path'] = $path;
}