[Run.Plugin.Calculator] Enable analyzer and fix warnings (#16998)

This commit is contained in:
CleanCodeDeveloper
2022-03-14 16:46:08 +01:00
committed by GitHub
parent 3e9c7f83c8
commit 79b2cdca7b
3 changed files with 8 additions and 8 deletions

View File

@@ -21,12 +21,10 @@ namespace Microsoft.PowerToys.Run.Plugin.Calculator
public const int RoundingDigits = 10;
public CalculateResult Interpret(string input)
{
// Using CurrentCulture this is user facing
return Interpret(input, CultureInfo.CurrentCulture);
}
/// <summary>
/// Interpret
/// </summary>
/// <param name="cultureInfo">Use CultureInfo.CurrentCulture if something is user facing</param>
public CalculateResult Interpret(string input, CultureInfo cultureInfo)
{
if (!CalculateHelper.InputValid(input))

View File

@@ -13,6 +13,8 @@
<AppendRuntimeIdentifierToOutputPath>false</AppendRuntimeIdentifierToOutputPath>
<Platforms>x64</Platforms>
<NeutralLanguage>en-US</NeutralLanguage>
<EnableNETAnalyzers>true</EnableNETAnalyzers>
<AnalysisMode>Recommended</AnalysisMode>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">