Skip to content

Commit

Permalink
Cleanup rebase errors in ActiveSolutionBoundTracker
Browse files Browse the repository at this point in the history
  • Loading branch information
georgii-borovinskikh-sonarsource authored and vnaskos-sonar committed Nov 27, 2024
1 parent 650228f commit e0afc29
Showing 1 changed file with 3 additions and 6 deletions.
9 changes: 3 additions & 6 deletions src/Integration/MefServices/ActiveSolutionBoundTracker.cs
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@
using SonarLint.VisualStudio.Core;
using SonarLint.VisualStudio.Core.Binding;
using SonarLint.VisualStudio.Core.ConfigurationScope;
using SonarLint.VisualStudio.Infrastructure.VS.Roslyn;
using SonarQube.Client;
using ErrorHandler = Microsoft.VisualStudio.ErrorHandler;

Expand All @@ -49,7 +48,6 @@ internal sealed class ActiveSolutionBoundTracker : IActiveSolutionBoundTracker,
private readonly IVsMonitorSelection vsMonitorSelection;
private readonly IBoundSolutionGitMonitor gitEventsMonitor;
private readonly IConfigScopeUpdater configScopeUpdater;
private readonly ISolutionRoslynAnalyzerManager solutionRoslynAnalyzerManager;
private readonly ILogger logger;
private readonly uint boundSolutionContextCookie;
private bool disposed;
Expand Down Expand Up @@ -81,7 +79,6 @@ public ActiveSolutionBoundTracker([Import(typeof(SVsServiceProvider))] IServiceP
this.configurationProvider = configurationProvider;
this.sonarQubeService = sonarQubeService;
this.configScopeUpdater = configScopeUpdater;
this.solutionRoslynAnalyzerManager = solutionRoslynAnalyzerManager;

// The solution changed inside the IDE
solutionTracker.ActiveSolutionChanged += OnActiveSolutionChanged;
Expand All @@ -100,7 +97,7 @@ public void HandleBindingChange(bool isBindingCleared)
return;
}

this.RaiseAnalyzersChangedIfBindingChanged(GetBindingConfiguration(), solutionTracker.CurrentSolutionName, isBindingCleared);
this.RaiseAnalyzersChangedIfBindingChanged(GetBindingConfiguration(), isBindingCleared);
}

private BindingConfiguration GetBindingConfiguration()
Expand Down Expand Up @@ -130,7 +127,7 @@ private async void OnActiveSolutionChanged(object sender, ActiveSolutionChangedE

gitEventsMonitor.Refresh();

RaiseAnalyzersChangedIfBindingChanged(connectionUpdatedSuccessfully ? newBindingConfiguration : BindingConfiguration.Standalone, args.SolutionName);
RaiseAnalyzersChangedIfBindingChanged(connectionUpdatedSuccessfully ? newBindingConfiguration : BindingConfiguration.Standalone);
}
catch (Exception ex) when (!ErrorHandler.IsCriticalException(ex))
{
Expand Down Expand Up @@ -165,7 +162,7 @@ private async Task<bool> UpdateConnectionAsync(BindingConfiguration bindingConfi
return isConnected;
}

private void RaiseAnalyzersChangedIfBindingChanged(BindingConfiguration newBindingConfiguration, string solutionName, bool? isBindingCleared = null)
private void RaiseAnalyzersChangedIfBindingChanged(BindingConfiguration newBindingConfiguration, bool? isBindingCleared = null)
{
configScopeUpdater.UpdateConfigScopeForCurrentSolution(newBindingConfiguration.Project);

Expand Down

0 comments on commit e0afc29

Please sign in to comment.