We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent bc997eb commit 9508abaCopy full SHA for 9508aba
src/Mvc/Mvc.ApiExplorer/src/EndpointMetadataApiDescriptionProvider.cs
@@ -405,9 +405,9 @@ private static void AddSupportedResponseTypes(
405
string? matchingDescription = null;
406
foreach (var metadata in responseMetadataTypes)
407
{
408
- if (metadata.StatusCode == apiResponseType.StatusCode &&
+ if (metadata?.StatusCode == apiResponseType?.StatusCode &&
409
TypesAreCompatible(apiResponseType?.Type, metadata?.Type) &&
410
- metadata.Description is not null)
+ metadata?.Description is not null)
411
412
matchingDescription = metadata.Description;
413
}
0 commit comments