Merge pull request #26272 from nextcloud/backport/26270/stable20
[stable20] Catch invalid cache source storage path
This commit is contained in:
commit
22626ae13f
|
@ -627,6 +627,10 @@ class Cache implements ICache {
|
|||
$targetPath = $this->normalize($targetPath);
|
||||
|
||||
$sourceData = $sourceCache->get($sourcePath);
|
||||
if ($sourceData === false) {
|
||||
throw new \Exception('Invalid source storage path: ' . $sourcePath);
|
||||
}
|
||||
|
||||
$sourceId = $sourceData['fileid'];
|
||||
$newParentId = $this->getParentId($targetPath);
|
||||
|
||||
|
|
Loading…
Reference in New Issue