Use GetNonGlobalPlugins() instead of field access

Replaced direct _nonGlobalPlugins field access with the GetNonGlobalPlugins() method to improve encapsulation and ensure up-to-date plugin data is used when retrieving non-global plugins by action keyword. No other logic was changed.
This commit is contained in:
Jack251970 2026-02-26 17:07:09 +08:00
parent 8760fe29ee
commit 452e60f3b5

View file

@ -380,7 +380,7 @@ namespace Flow.Launcher.Core.Plugin
if (query is null)
return Array.Empty<PluginPair>();
if (!_nonGlobalPlugins.TryGetValue(query.ActionKeyword, out var plugins))
if (!GetNonGlobalPlugins().TryGetValue(query.ActionKeyword, out var plugins))
{
if (dialogJump)
return [.. GetGlobalPlugins().Where(p => p.Plugin is IAsyncDialogJump && !PluginModified(p.Metadata.ID))];