You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: src/Http/Routing/src/ValidationEndpointFilterFactory.cs
+11-2Lines changed: 11 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -12,7 +12,6 @@ internal static class ValidationEndpointFilterFactory
12
12
{
13
13
privateconststringValidationContextJustification="The DisplayName property is always statically initialized in the ValidationContext through this codepath.";
14
14
15
-
[UnconditionalSuppressMessage("Trimming","IL2026:Members annotated with 'RequiresUnreferencedCodeAttribute' require dynamic access otherwise can break functionality when trimming application code",Justification=ValidationContextJustification)]
@@ -73,4 +72,14 @@ public static EndpointFilterDelegate Create(EndpointFilterFactoryContext context
73
72
returnnext;
74
73
};
75
74
}
75
+
76
+
/// <remarks>
77
+
/// ValidationContext is not trim-friendly in codepaths that don't
78
+
/// initialize an explicit DisplayName. We can suppress the warning here.
79
+
/// Eventually, this can be removed when the code is updated to
80
+
/// use https://github.com/dotnet/runtime/issues/113134.
81
+
/// </remarks>
82
+
[UnconditionalSuppressMessage("Trimming","IL2026:Members annotated with 'RequiresUnreferencedCodeAttribute' require dynamic access otherwise can break functionality when trimming application code",Justification=ValidationContextJustification)]
0 commit comments