File tree Expand file tree Collapse file tree 2 files changed +5
-5
lines changed
Microsoft.CodeAnalysis.Razor.Workspaces/DocumentPresentation
Microsoft.CodeAnalysis.Remote.Razor/UriPresentation Expand file tree Collapse file tree 2 files changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -15,13 +15,13 @@ internal static class UriPresentationHelper
15
15
{
16
16
if ( languageKind is not RazorLanguageKind . Html )
17
17
{
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.
19
19
return null ;
20
20
}
21
21
22
22
if ( uris is null || uris . Length == 0 )
23
23
{
24
- logger . LogInformation ( $ "No URIs were included in the request?") ;
24
+ logger . LogDebug ( $ "No URIs were included in the request?") ;
25
25
return null ;
26
26
}
27
27
@@ -33,14 +33,14 @@ internal static class UriPresentationHelper
33
33
// thinks they're just dragging the parent one, so we have to be a little bit clever with the filter here
34
34
if ( razorFileUri == null )
35
35
{
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.") ;
37
37
return null ;
38
38
}
39
39
40
40
var fileName = Path . GetFileName ( razorFileUri . GetAbsoluteOrUNCPath ( ) ) ;
41
41
if ( uris . Any ( uri => ! Path . GetFileName ( uri . GetAbsoluteOrUNCPath ( ) ) . StartsWith ( fileName , FilePathComparison . Instance ) ) )
42
42
{
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.") ;
44
44
return null ;
45
45
}
46
46
Original file line number Diff line number Diff line change @@ -68,7 +68,7 @@ internal sealed class RemoteUriPresentationService(
68
68
}
69
69
70
70
// 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 ] ) ;
72
72
if ( otherDocument is null )
73
73
{
74
74
return null ;
You can’t perform that action at this time.
0 commit comments