From 2ff439dc476fc0aabdf19b76a5bfe34fcbab8ef2 Mon Sep 17 00:00:00 2001 From: Clint Rutkas Date: Mon, 17 Aug 2020 14:52:27 -0700 Subject: [PATCH] fixing warnings, per ryan suggestion, suprressing warning now. we'll revisit the if debug blocks later (#6010) --- .../launcher/Wox.Plugin/SharedCommands/FilesFolders.cs | 6 ++++++ src/modules/launcher/Wox.Plugin/Wox.Plugin.csproj | 9 ++++++++- 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/src/modules/launcher/Wox.Plugin/SharedCommands/FilesFolders.cs b/src/modules/launcher/Wox.Plugin/SharedCommands/FilesFolders.cs index 30a39dffc1..932347438f 100644 --- a/src/modules/launcher/Wox.Plugin/SharedCommands/FilesFolders.cs +++ b/src/modules/launcher/Wox.Plugin/SharedCommands/FilesFolders.cs @@ -46,7 +46,9 @@ namespace Wox.Plugin.SharedCommands Copy(subdir.FullName, temppath); } } +#pragma warning disable CS0168 // Variable is declared but never used. Due to #if debug vs release statement catch (Exception e) +#pragma warning restore CS0168 // Variable is declared but never used { #if DEBUG throw e; @@ -76,7 +78,9 @@ namespace Wox.Plugin.SharedCommands return true; } +#pragma warning disable CS0168 // Variable is declared but never used. Due to #if debug vs release statement catch (Exception e) +#pragma warning restore CS0168 // Variable is declared but never used { #if DEBUG throw e; @@ -96,7 +100,9 @@ namespace Wox.Plugin.SharedCommands Directory.Delete(path, true); } } +#pragma warning disable CS0168 // Variable is declared but never used. Due to #if debug vs release statement catch (Exception e) +#pragma warning restore CS0168 // Variable is declared but never used { #if DEBUG throw e; diff --git a/src/modules/launcher/Wox.Plugin/Wox.Plugin.csproj b/src/modules/launcher/Wox.Plugin/Wox.Plugin.csproj index aa3f586690..572ee7757d 100644 --- a/src/modules/launcher/Wox.Plugin/Wox.Plugin.csproj +++ b/src/modules/launcher/Wox.Plugin/Wox.Plugin.csproj @@ -1,4 +1,4 @@ - + @@ -40,6 +40,13 @@ MinimumRecommendedRules.ruleset 4 + + true + + + + true +