diff options
author | Robin Appelman <robin@icewind.nl> | 2023-11-07 16:28:27 +0100 |
---|---|---|
committer | backportbot[bot] <backportbot[bot]@users.noreply.github.com> | 2024-01-31 18:28:05 +0000 |
commit | 90c57a6700796af63367220d9e2019aea4842fa0 (patch) | |
tree | e66543b54a7d3046e616d8b0dfd7e0bac318c778 /lib | |
parent | 1c4162bddfe27c54359d719ca41c90c11b7e4934 (diff) | |
download | nextcloud-server-90c57a6700796af63367220d9e2019aea4842fa0.tar.gz nextcloud-server-90c57a6700796af63367220d9e2019aea4842fa0.zip |
dont reuse etag for folders marked explicitly unscanned
Signed-off-by: Robin Appelman <robin@icewind.nl>
Diffstat (limited to 'lib')
-rw-r--r-- | lib/private/Files/Cache/Scanner.php | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/private/Files/Cache/Scanner.php b/lib/private/Files/Cache/Scanner.php index 9f99bbaab2b..371ae5ea2fe 100644 --- a/lib/private/Files/Cache/Scanner.php +++ b/lib/private/Files/Cache/Scanner.php @@ -203,7 +203,8 @@ class Scanner extends BasicEmitter implements IScanner { $fileId = $cacheData['fileid']; $data['fileid'] = $fileId; // only reuse data if the file hasn't explicitly changed - if (isset($data['storage_mtime']) && isset($cacheData['storage_mtime']) && $data['storage_mtime'] === $cacheData['storage_mtime']) { + $mtimeUnchanged = isset($data['storage_mtime']) && isset($cacheData['storage_mtime']) && $data['storage_mtime'] === $cacheData['storage_mtime']; + if ($mtimeUnchanged && $cacheData['size'] !== -1) { $data['mtime'] = $cacheData['mtime']; if (($reuseExisting & self::REUSE_SIZE) && ($data['size'] === -1)) { $data['size'] = $cacheData['size']; |