From: Björn Schießle Date: Wed, 8 May 2013 13:49:45 +0000 (+0200) Subject: update etag for for the touched file X-Git-Tag: v5.0.6~7^2~2 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=c43ec33ecb86892b308cc3b664553f14a115d2f9;p=nextcloud-server.git update etag for for the touched file --- diff --git a/lib/files/cache/updater.php b/lib/files/cache/updater.php index d9537e591da..f339ccd5b76 100644 --- a/lib/files/cache/updater.php +++ b/lib/files/cache/updater.php @@ -116,7 +116,15 @@ class Updater { * @param array $params */ static public function touchHook($params) { - self::writeUpdate($params['path']); + $path = $params['path']; + list($storage, $internalPath) = self::resolvePath($path); + $cache = $storage->getCache(); + $id = $cache->getId($internalPath); + if ($id !== -1) { + $cache->update($id, array('etag' => $storage->getETag($internalPath))); + self::correctFolder($parent, $time); + } + self::writeUpdate($path); } /**