From fdf0e4efa2292d893246b25cc8c62a3b08782962 Mon Sep 17 00:00:00 2001 From: Rankyn Bass Date: Sat, 13 Apr 2024 10:56:52 -0700 Subject: [PATCH] fix: MainPage.PatcherOnFail action --- lib/FFXIVQuickLauncher | 2 +- .../Components/MainPage/MainPage.cs | 16 ++-------------- 2 files changed, 3 insertions(+), 15 deletions(-) diff --git a/lib/FFXIVQuickLauncher b/lib/FFXIVQuickLauncher index 020dde9d..6e0829a9 160000 --- a/lib/FFXIVQuickLauncher +++ b/lib/FFXIVQuickLauncher @@ -1 +1 @@ -Subproject commit 020dde9d504f879a56b08fde570bcb4b5772ed3e +Subproject commit 6e0829a973b26db3aa95a9e60b96d73ff222a1ae diff --git a/src/XIVLauncher.Core/Components/MainPage/MainPage.cs b/src/XIVLauncher.Core/Components/MainPage/MainPage.cs index 09289f54..2028fe2e 100644 --- a/src/XIVLauncher.Core/Components/MainPage/MainPage.cs +++ b/src/XIVLauncher.Core/Components/MainPage/MainPage.cs @@ -1096,24 +1096,12 @@ void UpdatePatchStatus() return false; } - private void PatcherOnFail(PatchManager.FailReason reason, string versionId) + private void PatcherOnFail(PatchListEntry patch, string context) { var dlFailureLoc = Loc.Localize("PatchManDlFailure", "XIVLauncher could not verify the downloaded game files. Please restart and try again.\n\nThis usually indicates a problem with your internet connection.\nIf this error persists, try using a VPN set to Japan.\n\nContext: {0}\n{1}"); - switch (reason) - { - case PatchManager.FailReason.DownloadProblem: - App.ShowMessageBlocking(string.Format(dlFailureLoc, "Problem", versionId), "XIVLauncher Error"); - break; - - case PatchManager.FailReason.HashCheck: - App.ShowMessageBlocking(string.Format(dlFailureLoc, "IsHashCheckPass", versionId), "XIVLauncher Error"); - break; - - default: - throw new ArgumentOutOfRangeException(nameof(reason), reason, null); - } + App.ShowMessageBlocking(string.Format(dlFailureLoc, context, patch.VersionId), "XIVLauncher Error"); Environment.Exit(0); }