diff options
author | Andreas Fischer <bantu@owncloud.com> | 2014-02-16 00:50:03 +0100 |
---|---|---|
committer | Andreas Fischer <bantu@owncloud.com> | 2014-05-29 16:26:01 +0200 |
commit | a34aa1959aeeb9bc92c71c6f217db80a09cfbbd3 (patch) | |
tree | 51cd6ffe3562a0b64f038803d32b4d28cf9710e9 /lib | |
parent | a9b28323dd1116aef8c53d8e050380895fa1bb74 (diff) | |
download | nextcloud-server-a34aa1959aeeb9bc92c71c6f217db80a09cfbbd3.tar.gz nextcloud-server-a34aa1959aeeb9bc92c71c6f217db80a09cfbbd3.zip |
Cast to number instead of integer in OC\Files\Cache\Cache
Diffstat (limited to 'lib')
-rw-r--r-- | lib/private/files/cache/cache.php | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/lib/private/files/cache/cache.php b/lib/private/files/cache/cache.php index 3e4f6dfb132..59963f41e3d 100644 --- a/lib/private/files/cache/cache.php +++ b/lib/private/files/cache/cache.php @@ -142,11 +142,11 @@ class Cache { } else { //fix types $data['fileid'] = (int)$data['fileid']; - $data['size'] = (int)$data['size']; + $data['size'] = 0 + $data['size']; $data['mtime'] = (int)$data['mtime']; $data['storage_mtime'] = (int)$data['storage_mtime']; $data['encrypted'] = (bool)$data['encrypted']; - $data['unencrypted_size'] = (int)$data['unencrypted_size']; + $data['unencrypted_size'] = 0 + $data['unencrypted_size']; $data['storage'] = $this->storageId; $data['mimetype'] = $this->getMimetype($data['mimetype']); $data['mimepart'] = $this->getMimetype($data['mimepart']); @@ -532,9 +532,9 @@ class Cache { $result = \OC_DB::executeAudited($sql, array($id, $this->getNumericStorageId())); if ($row = $result->fetchRow()) { list($sum, $min, $unencryptedSum) = array_values($row); - $sum = (int)$sum; - $min = (int)$min; - $unencryptedSum = (int)$unencryptedSum; + $sum = 0 + $sum; + $min = 0 + $min; + $unencryptedSum = 0 + $unencryptedSum; if ($min === -1) { $totalSize = $min; } else { |