From eea2ed38be63b4774f9bc1a212f4543464181373 Mon Sep 17 00:00:00 2001 From: CleanCodeDeveloper <16760760+CleanCodeDeveloper@users.noreply.github.com> Date: Thu, 24 Feb 2022 11:09:10 +0100 Subject: [PATCH] [Microsoft.Plugin.WindowWalker] Enable analyzer and fix warnings --- .../Microsoft.Plugin.WindowWalker/Components/OpenWindows.cs | 2 +- .../Microsoft.Plugin.WindowWalker.csproj | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/src/modules/launcher/Plugins/Microsoft.Plugin.WindowWalker/Components/OpenWindows.cs b/src/modules/launcher/Plugins/Microsoft.Plugin.WindowWalker/Components/OpenWindows.cs index 77a6e623733b..4cd3be06a3d3 100644 --- a/src/modules/launcher/Plugins/Microsoft.Plugin.WindowWalker/Components/OpenWindows.cs +++ b/src/modules/launcher/Plugins/Microsoft.Plugin.WindowWalker/Components/OpenWindows.cs @@ -19,7 +19,7 @@ internal class OpenWindows /// /// PowerLauncher main executable /// - private static readonly string _powerLauncherExe = Path.GetFileName(Process.GetCurrentProcess().MainModule.FileName); + private static readonly string _powerLauncherExe = Path.GetFileName(Environment.ProcessPath); /// /// List of all the open windows diff --git a/src/modules/launcher/Plugins/Microsoft.Plugin.WindowWalker/Microsoft.Plugin.WindowWalker.csproj b/src/modules/launcher/Plugins/Microsoft.Plugin.WindowWalker/Microsoft.Plugin.WindowWalker.csproj index a33eae9c3120..85cb03872e1b 100644 --- a/src/modules/launcher/Plugins/Microsoft.Plugin.WindowWalker/Microsoft.Plugin.WindowWalker.csproj +++ b/src/modules/launcher/Plugins/Microsoft.Plugin.WindowWalker/Microsoft.Plugin.WindowWalker.csproj @@ -13,6 +13,8 @@ false x64 en-US + true + Recommended