Skip to content

Commit 9508aba

Browse files
committed
Fix build
1 parent bc997eb commit 9508aba

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/Mvc/Mvc.ApiExplorer/src/EndpointMetadataApiDescriptionProvider.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -405,9 +405,9 @@ private static void AddSupportedResponseTypes(
405405
string? matchingDescription = null;
406406
foreach (var metadata in responseMetadataTypes)
407407
{
408-
if (metadata.StatusCode == apiResponseType.StatusCode &&
408+
if (metadata?.StatusCode == apiResponseType?.StatusCode &&
409409
TypesAreCompatible(apiResponseType?.Type, metadata?.Type) &&
410-
metadata.Description is not null)
410+
metadata?.Description is not null)
411411
{
412412
matchingDescription = metadata.Description;
413413
}

0 commit comments

Comments
 (0)