Skip to content

Commit b16b9c8

Browse files
committed
clarified intend with linq .Single() instead of directly accessing index [0].
1 parent ed54aa6 commit b16b9c8

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

RetailCoder.VBE/UI/Command/FindAllReferencesCommand.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ public override void Execute(object parameter)
5656

5757
if (viewModel.SearchResults.Count == 1)
5858
{
59-
_navigateCommand.Execute(viewModel.SearchResults[0].GetNavigationArgs());
59+
_navigateCommand.Execute(viewModel.SearchResults.Single().GetNavigationArgs());
6060
return;
6161
}
6262

0 commit comments

Comments
 (0)