Show the host in the download failed error message.

This commit is contained in:
Matthias Mailänder
2022-11-23 00:26:27 +01:00
committed by abcdefg30
parent 6f4f0c4e8f
commit 14b5504ea7

View File

@@ -139,11 +139,12 @@ namespace OpenRA.Mods.Common.Widgets.Logic
Action<string> onError = s => Game.RunAfterTick(() =>
{
Log.Write("install", "Download failed: " + s);
var host = downloadHost ?? modData.Translation.GetString(UnknownHost);
Log.Write("install", $"Download from {host} failed: " + s);
progressBar.Indeterminate = false;
progressBar.Percentage = 100;
getStatusText = () => "Error: " + s;
getStatusText = () => $"{host}: Error: {s}";
retryButton.IsVisible = () => true;
cancelButton.OnClick = Ui.CloseWindow;
});