From a00ae1d0c5276a8c533e395f136a44519b1374e9 Mon Sep 17 00:00:00 2001 From: RisaDev <151885272+RisaDev@users.noreply.github.com> Date: Sat, 30 Mar 2024 19:35:44 +0300 Subject: [PATCH] Fixed legacy IPC not handling exceptions thrown by ProfileManager.RemoveTemporaryProfile, changelog text fix --- .../Api/Compatibility/CustomizePlusLegacyIpc.cs | 10 +++++++++- CustomizePlus/UI/Windows/CPlusChangeLog.cs | 2 +- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/CustomizePlus/Api/Compatibility/CustomizePlusLegacyIpc.cs b/CustomizePlus/Api/Compatibility/CustomizePlusLegacyIpc.cs index b24fcf4..40ec55c 100644 --- a/CustomizePlus/Api/Compatibility/CustomizePlusLegacyIpc.cs +++ b/CustomizePlus/Api/Compatibility/CustomizePlusLegacyIpc.cs @@ -22,6 +22,7 @@ using CustomizePlus.Armatures.Events; using CustomizePlus.Armatures.Data; using CustomizePlus.GameData.Extensions; using Penumbra.GameData.Interop; +using CustomizePlus.Profiles.Exceptions; namespace CustomizePlus.Api.Compatibility; @@ -265,7 +266,14 @@ public class CustomizePlusLegacyIpc : IDisposable return; }*/ - _profileManager.RemoveTemporaryProfile(actor); + try + { + _profileManager.RemoveTemporaryProfile(actor); + } + catch (Exception ex) + { + _logger.Warning($"[LEGACY IPC DO NOT USE] Unable to revert character. Character: {character?.Name}, exception: {ex}"); + } } private string GetBase64String(string data) diff --git a/CustomizePlus/UI/Windows/CPlusChangeLog.cs b/CustomizePlus/UI/Windows/CPlusChangeLog.cs index c4711a1..9f1c669 100644 --- a/CustomizePlus/UI/Windows/CPlusChangeLog.cs +++ b/CustomizePlus/UI/Windows/CPlusChangeLog.cs @@ -40,7 +40,7 @@ public class CPlusChangeLog .RegisterEntry("Selected default profile can no longer be changed if profile set as default is enabled. (2.0.2.1)") .RegisterEntry("Profiles can no longer be enabled/disabled while editor is active. (2.0.2.1)") .RegisterEntry("Fixed incorrect warning message priorities in main window. (2.0.2.1)") - .RegisterEntry("Fixed \"Limit to my creatures\" not ignoring objects other than minions and mounts. (2.0.2.1)") + .RegisterEntry("Fixed \"Limit to my creatures\" not ignoring objects other than summons, minions and mounts. (2.0.2.1)") .RegisterEntry("Fixed text in various places. (2.0.2.1)"); private static void Add2_0_1_0(Changelog log)