Skip to content

Commit 306cd32

Browse files
committed
chore: code linting
Signed-off-by: Vincent Biret <[email protected]>
1 parent 081e251 commit 306cd32

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/Microsoft.OpenApi/Models/OpenApiSchema.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -699,11 +699,11 @@ private static bool HasMultipleTypes(JsonSchemaType schemaType)
699699
schemaTypeNumeric != (int)JsonSchemaType.Null;
700700
}
701701

702-
private void UpCastSchemaTypeToV31(JsonSchemaType type, IOpenApiWriter writer)
702+
private static void UpCastSchemaTypeToV31(JsonSchemaType type, IOpenApiWriter writer)
703703
{
704704
// create a new array and insert the type and "null" as values
705705
var temporaryType = type | JsonSchemaType.Null;
706-
var list = (from JsonSchemaType? flag in jsonSchemaTypeValues// Check if the flag is set in 'type' using a bitwise AND operation
706+
var list = (from JsonSchemaType flag in jsonSchemaTypeValues// Check if the flag is set in 'type' using a bitwise AND operation
707707
where temporaryType.HasFlag(flag)
708708
select flag.ToIdentifier()).ToList();
709709
if (list.Count > 1)
@@ -736,7 +736,7 @@ private void DowncastTypeArrayToV2OrV3(JsonSchemaType schemaType, IOpenApiWriter
736736

737737
if (!HasMultipleTypes(schemaType ^ JsonSchemaType.Null) && (schemaType & JsonSchemaType.Null) == JsonSchemaType.Null) // checks for two values and one is null
738738
{
739-
foreach (JsonSchemaType? flag in jsonSchemaTypeValues)
739+
foreach (JsonSchemaType flag in jsonSchemaTypeValues)
740740
{
741741
// Skip if the flag is not set or if it's the Null flag
742742
if (schemaType.HasFlag(flag) && flag != JsonSchemaType.Null)

0 commit comments

Comments
 (0)