mirror of
https://github.com/nextcloud/server.git
synced 2026-04-15 22:11:17 -04:00
fix(cache): always require updates if mtime is null
- Resolves https://github.com/nextcloud/server/issues/51941 Due to strong typings we introduced the parameter needs to be an integer. Previously it was `null` which was equal to `0`. So if there is no storage mtime we need to update the cache. Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
This commit is contained in:
parent
a35f4b16ac
commit
3a09acebd2
1 changed files with 1 additions and 1 deletions
|
|
@ -118,7 +118,7 @@ class Watcher implements IWatcher {
|
|||
public function needsUpdate($path, $cachedData) {
|
||||
if ($this->watchPolicy === self::CHECK_ALWAYS or ($this->watchPolicy === self::CHECK_ONCE and !in_array($path, $this->checkedPaths))) {
|
||||
$this->checkedPaths[] = $path;
|
||||
return $this->storage->hasUpdated($path, $cachedData['storage_mtime']);
|
||||
return $cachedData['storage_mtime'] === null || $this->storage->hasUpdated($path, $cachedData['storage_mtime']);
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue