Merge pull request #45233 from nextcloud/fix/touch-propagate-size

fix: Avoid updating size when calling touch on a file
This commit is contained in:
Côme Chilliet 2024-05-13 11:48:06 +02:00 committed by GitHub
commit 2d40dae4af
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -1182,7 +1182,7 @@ class View {
$this->writeUpdate($storage, $internalPath, null, $isCreateOperation ? $sizeDifference : null);
}
if ($result !== false && in_array('touch', $hooks)) {
$this->writeUpdate($storage, $internalPath, $extraParam);
$this->writeUpdate($storage, $internalPath, $extraParam, 0);
}
if ((in_array('write', $hooks) || in_array('delete', $hooks)) && ($operation !== 'fopen' || $result === false)) {