Skip to content

Commit

Permalink
Fix analyzer warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
ErikEJ committed Dec 27, 2024
1 parent e9ffeb5 commit 1e439b5
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 3 deletions.
1 change: 1 addition & 0 deletions src/GUI/EFCorePowerTools/GlobalSuppressions.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,4 @@
using System.Diagnostics.CodeAnalysis;

[assembly: SuppressMessage("StyleCop.CSharp.DocumentationRules", "SA1633:File should have header", Justification = "Generated by tooling")]
[assembly: SuppressMessage("Minor Code Smell", "S2325:Methods and properties that don't access instance data should be static", Justification = "Will do this later")]
2 changes: 1 addition & 1 deletion src/GUI/Shared/Extensions/ProjectExtensions.cs
Original file line number Diff line number Diff line change
Expand Up @@ -361,7 +361,7 @@ private static async Task<string> GetTargetFrameworkMonikersAsync(Project projec
{
string result = null;

project.GetItemInfo(out IVsHierarchy hierarchy, out uint itemId, out _);
project.GetItemInfo(out IVsHierarchy hierarchy, out uint _, out _);

await ThreadHelper.JoinableTaskFactory.SwitchToMainThreadAsync();

Expand Down
2 changes: 1 addition & 1 deletion src/GUI/Shared/Handlers/ModelAnalyzerHandler.cs
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ public async System.Threading.Tasks.Task GenerateAsync(string outputPath, Projec
return;
}

if (!Version.TryParse(result.Item2, out Version version))
if (!Version.TryParse(result.Item2, out Version _))
{
VSHelper.ShowError(string.Format(ModelAnalyzerLocale.CurrentEFCoreVersion, result.Item2));
if (!result.Item1)
Expand Down
2 changes: 1 addition & 1 deletion src/GUI/Shared/Helpers/VsDataHelper.cs
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ internal static async System.Threading.Tasks.Task<bool> IsDdexProviderInstalledA
{
var providerManager = await VS.GetServiceAsync<IVsDataProviderManager, IVsDataProviderManager>();
return providerManager != null &&
providerManager.Providers.TryGetValue(id, out IVsDataProvider provider);
providerManager.Providers.TryGetValue(id, out IVsDataProvider _);
}
catch
{
Expand Down

0 comments on commit 1e439b5

Please sign in to comment.