Skip to content

Commit 45a3e1f

Browse files
committed
PR Feedback
1 parent ab4c134 commit 45a3e1f

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

src/Razor/src/Microsoft.CodeAnalysis.Razor.Workspaces/DocumentPresentation/UriPresentationHelper.cs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,13 +15,13 @@ internal static class UriPresentationHelper
1515
{
1616
if (languageKind is not RazorLanguageKind.Html)
1717
{
18-
// We don't do anything for HTML
18+
// Component tags can only be inserted into Html contexts, so if this isn't Html there is nothing we can do.
1919
return null;
2020
}
2121

2222
if (uris is null || uris.Length == 0)
2323
{
24-
logger.LogInformation($"No URIs were included in the request?");
24+
logger.LogDebug($"No URIs were included in the request?");
2525
return null;
2626
}
2727

@@ -33,14 +33,14 @@ internal static class UriPresentationHelper
3333
// thinks they're just dragging the parent one, so we have to be a little bit clever with the filter here
3434
if (razorFileUri == null)
3535
{
36-
logger.LogInformation($"No file in the drop was a razor file URI.");
36+
logger.LogDebug($"No file in the drop was a razor file URI.");
3737
return null;
3838
}
3939

4040
var fileName = Path.GetFileName(razorFileUri.GetAbsoluteOrUNCPath());
4141
if (uris.Any(uri => !Path.GetFileName(uri.GetAbsoluteOrUNCPath()).StartsWith(fileName, FilePathComparison.Instance)))
4242
{
43-
logger.LogInformation($"One or more URIs were not a child file of the main .razor file.");
43+
logger.LogDebug($"One or more URIs were not a child file of the main .razor file.");
4444
return null;
4545
}
4646

src/Razor/src/Microsoft.CodeAnalysis.Remote.Razor/UriPresentation/RemoteUriPresentationService.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ internal sealed class RemoteUriPresentationService(
6868
}
6969

7070
// We assume linked documents would produce the same component tag so just take the first
71-
var otherDocument = razorDocument.Project.Solution.GetAdditionalDocument(ids.First());
71+
var otherDocument = razorDocument.Project.Solution.GetAdditionalDocument(ids[0]);
7272
if (otherDocument is null)
7373
{
7474
return null;

0 commit comments

Comments
 (0)