From e5bf375b42afb3ac21860e8b43a7bd9d395e2d21 Mon Sep 17 00:00:00 2001 From: JonKazama-Hellion Date: Thu, 7 May 2026 07:53:52 +0200 Subject: [PATCH] fix(plugin): flush DeferredSaveFrames in Dispose before service teardown --- HellionChat/Plugin.cs | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/HellionChat/Plugin.cs b/HellionChat/Plugin.cs index d0d349c..f5f5cbd 100755 --- a/HellionChat/Plugin.cs +++ b/HellionChat/Plugin.cs @@ -536,6 +536,14 @@ public sealed class Plugin : IDalamudPlugin Framework.Update -= FrameworkUpdate; GameFunctions.GameFunctions.SetChatInteractable(true); + // FrameworkUpdate would have fired the pending save in N frames, + // but we just unsubscribed it. -1 is the idle sentinel. + if (DeferredSaveFrames >= 0) + { + SaveConfig(); + DeferredSaveFrames = -1; + } + HonorificService?.Dispose(); WindowSystem?.RemoveAllWindows();