Merge pull request #22220 from owncloud/enc-fixfilesizelogicwithpartfile

Fix part file partial cache logic in encryption code
This commit is contained in:
Thomas Müller 2016-02-09 11:06:22 +01:00
commit 254e0fa71a
1 changed files with 7 additions and 1 deletions

View File

@ -129,9 +129,15 @@ class Encryption extends Wrapper {
if (isset($this->unencryptedSize[$fullPath])) {
$size = $this->unencryptedSize[$fullPath];
// update file cache
if ($info) {
$info = $info->getData();
} else {
$info = [];
}
$info['encrypted'] = true;
$info['size'] = $size;
$this->getCache()->put($path, $info->getData());
$this->getCache()->put($path, $info);
return $size;
}