Skip to content

Commit d74e2b6

Browse files
authored
Merge pull request #35369 from nextcloud/backport/35353/stable23
[stable23] Update cache when file size === 0
2 parents 106449f + 36243c5 commit d74e2b6

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

lib/private/Files/View.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1179,13 +1179,13 @@ private function basicOperation($operation, $path, $hooks = [], $extraParam = nu
11791179
throw $e;
11801180
}
11811181

1182-
if ($result && in_array('delete', $hooks)) {
1182+
if ($result !== false && in_array('delete', $hooks)) {
11831183
$this->removeUpdate($storage, $internalPath);
11841184
}
1185-
if ($result && in_array('write', $hooks, true) && $operation !== 'fopen' && $operation !== 'touch') {
1185+
if ($result !== false && in_array('write', $hooks, true) && $operation !== 'fopen' && $operation !== 'touch') {
11861186
$this->writeUpdate($storage, $internalPath);
11871187
}
1188-
if ($result && in_array('touch', $hooks)) {
1188+
if ($result !== false && in_array('touch', $hooks)) {
11891189
$this->writeUpdate($storage, $internalPath, $extraParam);
11901190
}
11911191

0 commit comments

Comments
 (0)