Skip to content

Commit 84a068a

Browse files
fix type hints
Signed-off-by: Robin Appelman <[email protected]>
1 parent efeaca4 commit 84a068a

1 file changed

Lines changed: 2 additions & 3 deletions

File tree

lib/private/Files/Cache/Cache.php

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -894,11 +894,11 @@ public function calculateFolderSize($path, $entry = null) {
894894
* inner function because we can't add new params to the public function without breaking any child classes
895895
*
896896
* @param string $path
897-
* @param array $entry (optional) meta data of the folder
897+
* @param array|null|ICacheEntry $entry (optional) meta data of the folder
898898
* @param bool $ignoreUnknown don't mark the folder size as unknown if any of it's children are unknown
899899
* @return int
900900
*/
901-
protected function calculateFolderSizeInner(string $path, array $entry = null, bool $ignoreUnknown = false) {
901+
protected function calculateFolderSizeInner(string $path, $entry = null, bool $ignoreUnknown = false) {
902902
$totalSize = 0;
903903
if (is_null($entry) || !isset($entry['fileid'])) {
904904
$entry = $this->get($path);
@@ -958,7 +958,6 @@ protected function calculateFolderSizeInner(string $path, array $entry = null, b
958958
$shouldWriteUnEncryptedSize = $unencryptedMax > 0 || $totalSize === 0 || $entry['unencrypted_size'] > 0;
959959
if ($entry['size'] !== $totalSize || ($entry['unencrypted_size'] !== $unencryptedTotal && $shouldWriteUnEncryptedSize)) {
960960
if ($shouldWriteUnEncryptedSize) {
961-
962961
// if all children have an unencrypted size of 0, just set the folder unencrypted size to 0 instead of summing the sizes
963962
if ($unencryptedMax === 0) {
964963
$unencryptedTotal = 0;

0 commit comments

Comments
 (0)