From 59f3eeecf22680bc0932ee2e30eea75f890e4236 Mon Sep 17 00:00:00 2001 From: Hongtao Zhang Date: Thu, 16 May 2024 22:21:35 -0500 Subject: [PATCH] add a close overload for jsonrpcpluginv2 --- Flow.Launcher.Core/Plugin/JsonRPCPluginV2.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Flow.Launcher.Core/Plugin/JsonRPCPluginV2.cs b/Flow.Launcher.Core/Plugin/JsonRPCPluginV2.cs index 46c72624a..9b094e315 100644 --- a/Flow.Launcher.Core/Plugin/JsonRPCPluginV2.cs +++ b/Flow.Launcher.Core/Plugin/JsonRPCPluginV2.cs @@ -139,11 +139,11 @@ namespace Flow.Launcher.Core.Plugin return Task.CompletedTask; } - public virtual ValueTask DisposeAsync() + public virtual async ValueTask DisposeAsync() { + await RPC.InvokeAsync("close"); RPC?.Dispose(); ErrorStream?.Dispose(); - return ValueTask.CompletedTask; } } }