Skip to content

Commit

Permalink
Update src/Microsoft.OpenApi/Models/OpenApiMediaType.cs
Browse files Browse the repository at this point in the history
Co-authored-by: Andrew Omondi <andrueastman@users.noreply.github.com>
  • Loading branch information
MaggieKimani1 and andrueastman authored Aug 5, 2024
1 parent 28142d5 commit 38ba98e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Microsoft.OpenApi/Models/OpenApiMediaType.cs
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ private void SerializeExamples(IOpenApiWriter writer, IDictionary<string, OpenAp
/* Special case for writing out empty arrays as valid response examples
* Check if there is any example with an empty array as its value and set the flag `hasEmptyArray` to true
* */
var hasEmptyArray = examples.Values.Any(example =>
var hasEmptyArray = examples.Values.Any( static example =>
example.Value is OpenApiArray arr && arr.Count == 0
);

Expand Down

0 comments on commit 38ba98e

Please sign in to comment.