diff options
author | Andy Scherzinger <info@andy-scherzinger.de> | 2024-07-25 19:37:30 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-07-25 19:37:30 +0200 |
commit | 4f2a29adf95c57bef5d01f27c8b741a9840e82b3 (patch) | |
tree | 964245a9302baa5b49f215642fb1f82acfa5987b /lib | |
parent | 2e353d88498e841a468eaa28874f18ba20c7a9b1 (diff) | |
parent | 2b0bc8b310aef675af35373fbc8a7884869f7d05 (diff) | |
download | nextcloud-server-4f2a29adf95c57bef5d01f27c8b741a9840e82b3.tar.gz nextcloud-server-4f2a29adf95c57bef5d01f27c8b741a9840e82b3.zip |
Merge pull request #46672 from nextcloud/fix/preview-invalid-id
Avoid using partial file info as valid one
Diffstat (limited to 'lib')
-rw-r--r-- | lib/private/Files/View.php | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/lib/private/Files/View.php b/lib/private/Files/View.php index c20ff9f3c02..0e5e433ccb6 100644 --- a/lib/private/Files/View.php +++ b/lib/private/Files/View.php @@ -1338,9 +1338,6 @@ class View { if (!Filesystem::isValidPath($path)) { return false; } - if (Cache\Scanner::isPartialFile($path)) { - return $this->getPartFileInfo($path); - } $relativePath = $path; $path = Filesystem::normalizePath($this->fakeRoot . '/' . $path); @@ -1351,6 +1348,10 @@ class View { $data = $this->getCacheEntry($storage, $internalPath, $relativePath); if (!$data instanceof ICacheEntry) { + if (Cache\Scanner::isPartialFile($relativePath)) { + return $this->getPartFileInfo($relativePath); + } + return false; } |