Skip to content

Commit

Permalink
fix: Improve wording, styling and error handling of the auto updater
Browse files Browse the repository at this point in the history
  • Loading branch information
mitelg committed Sep 25, 2023
1 parent b025f04 commit 197a12d
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -169,12 +169,8 @@ public function downloadFile($sourceUri, $destinationUri, $totalSize, $hash)
$error = curl_error($ch);
curl_close($ch);

if ($isError && !$isHalted) {
throw new Exception('Wrong http code');
}

if ($result === false && !$isHalted) {
throw new Exception($error);
if (($result === false || $isError) && !$isHalted) {
throw new Exception($error ?: 'Unknown error');
}

clearstatcache(false, $partFile->getPathname());
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ security_update_window/text = "<h2>Warning!</h2>A new security update is availab
security_update_window/cancel = "Close"
security_update_window/update = "Open software update"
ftp/invalid_permissions = "Invalid file permissions"
release_information = "You can access the release information of [1] here."
release_information = "You can see the current release information for [1] here."

[de_DE]
cancel = "Abbrechen"
Expand Down Expand Up @@ -162,4 +162,4 @@ security_update_window/text = "<h2>Achtung!</h2>Ein neues Sicherheitsupdate ist
security_update_window/cancel = "Schließen"
security_update_window/update = "Softwareaktualisierung öffnen"
ftp/invalid_permissions = "Invalide Datei Rechte"
release_information = "Du kannst die aktuellen release Information von [1] hier beziehen."
release_information = "Du kannst die aktuellen Release-Informationen zu [1] hier einsehen."
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,7 @@ Ext.define('Shopware.apps.SwagUpdate.view.Window', {
var me = this;

var text = Ext.String.format(
'<div class="swag-update-changelog"><a href="[0]">{s name="release_information"}You can access the release information of [1] here.{/s}</a></div>',
'<div class="swag-update-changelog"><br><a href="[0]">{s name="release_information"}{/s}</a></div>',
me.changelog.get('changelog'),
me.changelog.get('version')
);
Expand Down

0 comments on commit 197a12d

Please sign in to comment.