Skip to content

Commit

Permalink
Merge pull request #147 from nextcloud/bugfix/fatal-int-error
Browse files Browse the repository at this point in the history
Fix fatal error caused by wrong return type in sparkle update length
  • Loading branch information
claucambra authored Jul 1, 2024
2 parents 6e52105 + 6a61f1c commit 120a5b4
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/Response.php
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ private function getSparkleUpdateSignature(array $updateVersion) : string {
return $updateVersion[$updateSignatureKey];
}

private function getSparkleUpdateLength(array $updateVersion) : string {
private function getSparkleUpdateLength(array $updateVersion) : int {
$updateLengthKey = $this->isFileProvider ? 'fileProviderLength' : 'length';
return $updateVersion[$updateLengthKey];
}
Expand Down
4 changes: 2 additions & 2 deletions tests/unit/ResponseTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ public function updateDataProvider(): array
'downloadurl' => 'https://download.owncloud.com/desktop/stable/ownCloud-2.2.2.3472.pkg',
'sparkleDownloadUrl' => 'https://download.owncloud.com/desktop/stable/ownCloud-2.2.2.3472.pkg.tbz',
'signature' => 'MC0CFQDmXR6biDmNVW7TvMh0bfPPTzCvtwIUCzASgpzYdi4lltOnwbFCeQwgDjY=',
'length' => '62738920',
'length' => 62738920,
]
],
'beta' => [
Expand All @@ -71,7 +71,7 @@ public function updateDataProvider(): array
'downloadurl' => 'https://download.nextcloud.com/desktop/stable/Nextcloud-2.2.2-rc2.pkg',
'sparkleDownloadUrl' => 'https://download.nextcloud.com/desktop/stable/Nextcloud-2.2.2-rc1.pkg.tbz',
'signature' => 'MC0CFQDmXR6biDmNVW7TvMh0bfPPTzCvtwIUCzASgpzYdi4lltOnwbFCeQwgDjY=',
'length' => '62738920',
'length' => 62738920,
]
],
'daily' => [
Expand Down

0 comments on commit 120a5b4

Please sign in to comment.