提交 0d837289 编写于 作者: B Ben Lichtman

Respond to CR

上级 9d99d0a0
...@@ -97,11 +97,7 @@ public void AugmentPeekSession(IPeekSession session, IList<IPeekableItem> peekab ...@@ -97,11 +97,7 @@ public void AugmentPeekSession(IPeekSession session, IList<IPeekableItem> peekab
symbol = symbol.GetOriginalUnreducedDefinition(); symbol = symbol.GetOriginalUnreducedDefinition();
// Get the symbol back from the originating workspace // Get the symbol back from the originating workspace
var symbolMappingService = document.Project.Solution.Workspace.Services.GetService<ISymbolMappingService>(); var symbolMappingService = document.Project.Solution.Workspace.Services.GetRequiredService<ISymbolMappingService>();
if (symbolMappingService == null)
{
return;
}
var mappingResult = symbolMappingService.MapSymbolAsync(document, symbol, cancellationToken) var mappingResult = symbolMappingService.MapSymbolAsync(document, symbol, cancellationToken)
.WaitAndGetResult(cancellationToken); .WaitAndGetResult(cancellationToken);
...@@ -124,11 +120,7 @@ public void AugmentPeekSession(IPeekSession session, IList<IPeekableItem> peekab ...@@ -124,11 +120,7 @@ public void AugmentPeekSession(IPeekSession session, IList<IPeekableItem> peekab
if (navigableItems != null) if (navigableItems != null)
{ {
var workspace = project.Solution.Workspace; var workspace = project.Solution.Workspace;
var navigationService = workspace.Services.GetService<IDocumentNavigationService>(); var navigationService = workspace.Services.GetRequiredService<IDocumentNavigationService>();
if (navigationService == null)
{
yield break;
}
foreach (var item in navigableItems) foreach (var item in navigableItems)
{ {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册