Skip to content

Commit 7b131bb

Browse files
committed
Rename emitted variable to isInlinedSchema
1 parent b895d2d commit 7b131bb

9 files changed

+18
-18
lines changed

src/OpenApi/gen/XmlCommentGenerator.Emitter.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -459,10 +459,10 @@ public Task TransformAsync(OpenApiSchema schema, OpenApiSchemaTransformerContext
459459
}
460460
}
461461
462-
var isPropertyInlinedSchema = schema.Metadata is null
462+
var isInlinedSchema = schema.Metadata is null
463463
|| !schema.Metadata.TryGetValue("x-schema-id", out var schemaId)
464464
|| string.IsNullOrEmpty(schemaId as string);
465-
if (isPropertyInlinedSchema && context.JsonPropertyInfo is { AttributeProvider: PropertyInfo propertyInfo })
465+
if (isInlinedSchema && context.JsonPropertyInfo is { AttributeProvider: PropertyInfo propertyInfo })
466466
{
467467
// Apply comments from the property
468468
if (XmlCommentCache.Cache.TryGetValue(DocumentationCommentIdHelper.NormalizeDocId(propertyInfo.CreateDocumentationId()), out var propertyComment))

src/OpenApi/test/Microsoft.AspNetCore.OpenApi.SourceGenerators.Tests/snapshots/AddOpenApiTests.CanInterceptAddOpenApi#OpenApiXmlCommentSupport.generated.verified.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -441,10 +441,10 @@ public Task TransformAsync(OpenApiSchema schema, OpenApiSchemaTransformerContext
441441
}
442442
}
443443

444-
var isPropertyInlinedSchema = schema.Metadata is null
444+
var isInlinedSchema = schema.Metadata is null
445445
|| !schema.Metadata.TryGetValue("x-schema-id", out var schemaId)
446446
|| string.IsNullOrEmpty(schemaId as string);
447-
if (isPropertyInlinedSchema && context.JsonPropertyInfo is { AttributeProvider: PropertyInfo propertyInfo })
447+
if (isInlinedSchema && context.JsonPropertyInfo is { AttributeProvider: PropertyInfo propertyInfo })
448448
{
449449
// Apply comments from the property
450450
if (XmlCommentCache.Cache.TryGetValue(DocumentationCommentIdHelper.NormalizeDocId(propertyInfo.CreateDocumentationId()), out var propertyComment))

src/OpenApi/test/Microsoft.AspNetCore.OpenApi.SourceGenerators.Tests/snapshots/AdditionalTextsTests.CanHandleXmlForSchemasInAdditionalTexts#OpenApiXmlCommentSupport.generated.verified.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -470,10 +470,10 @@ public Task TransformAsync(OpenApiSchema schema, OpenApiSchemaTransformerContext
470470
}
471471
}
472472

473-
var isPropertyInlinedSchema = schema.Metadata is null
473+
var isInlinedSchema = schema.Metadata is null
474474
|| !schema.Metadata.TryGetValue("x-schema-id", out var schemaId)
475475
|| string.IsNullOrEmpty(schemaId as string);
476-
if (isPropertyInlinedSchema && context.JsonPropertyInfo is { AttributeProvider: PropertyInfo propertyInfo })
476+
if (isInlinedSchema && context.JsonPropertyInfo is { AttributeProvider: PropertyInfo propertyInfo })
477477
{
478478
// Apply comments from the property
479479
if (XmlCommentCache.Cache.TryGetValue(DocumentationCommentIdHelper.NormalizeDocId(propertyInfo.CreateDocumentationId()), out var propertyComment))

src/OpenApi/test/Microsoft.AspNetCore.OpenApi.SourceGenerators.Tests/snapshots/CompletenessTests.SupportsAllXmlTagsOnSchemas#OpenApiXmlCommentSupport.generated.verified.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -562,10 +562,10 @@ public Task TransformAsync(OpenApiSchema schema, OpenApiSchemaTransformerContext
562562
}
563563
}
564564

565-
var isPropertyInlinedSchema = schema.Metadata is null
565+
var isInlinedSchema = schema.Metadata is null
566566
|| !schema.Metadata.TryGetValue("x-schema-id", out var schemaId)
567567
|| string.IsNullOrEmpty(schemaId as string);
568-
if (isPropertyInlinedSchema && context.JsonPropertyInfo is { AttributeProvider: PropertyInfo propertyInfo })
568+
if (isInlinedSchema && context.JsonPropertyInfo is { AttributeProvider: PropertyInfo propertyInfo })
569569
{
570570
// Apply comments from the property
571571
if (XmlCommentCache.Cache.TryGetValue(DocumentationCommentIdHelper.NormalizeDocId(propertyInfo.CreateDocumentationId()), out var propertyComment))

src/OpenApi/test/Microsoft.AspNetCore.OpenApi.SourceGenerators.Tests/snapshots/OperationTests.SupportsXmlCommentsOnOperationsFromControllers#OpenApiXmlCommentSupport.generated.verified.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -445,10 +445,10 @@ public Task TransformAsync(OpenApiSchema schema, OpenApiSchemaTransformerContext
445445
}
446446
}
447447

448-
var isPropertyInlinedSchema = schema.Metadata is null
448+
var isInlinedSchema = schema.Metadata is null
449449
|| !schema.Metadata.TryGetValue("x-schema-id", out var schemaId)
450450
|| string.IsNullOrEmpty(schemaId as string);
451-
if (isPropertyInlinedSchema && context.JsonPropertyInfo is { AttributeProvider: PropertyInfo propertyInfo })
451+
if (isInlinedSchema && context.JsonPropertyInfo is { AttributeProvider: PropertyInfo propertyInfo })
452452
{
453453
// Apply comments from the property
454454
if (XmlCommentCache.Cache.TryGetValue(DocumentationCommentIdHelper.NormalizeDocId(propertyInfo.CreateDocumentationId()), out var propertyComment))

src/OpenApi/test/Microsoft.AspNetCore.OpenApi.SourceGenerators.Tests/snapshots/OperationTests.SupportsXmlCommentsOnOperationsFromMinimalApis#OpenApiXmlCommentSupport.generated.verified.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -463,10 +463,10 @@ public Task TransformAsync(OpenApiSchema schema, OpenApiSchemaTransformerContext
463463
}
464464
}
465465

466-
var isPropertyInlinedSchema = schema.Metadata is null
466+
var isInlinedSchema = schema.Metadata is null
467467
|| !schema.Metadata.TryGetValue("x-schema-id", out var schemaId)
468468
|| string.IsNullOrEmpty(schemaId as string);
469-
if (isPropertyInlinedSchema && context.JsonPropertyInfo is { AttributeProvider: PropertyInfo propertyInfo })
469+
if (isInlinedSchema && context.JsonPropertyInfo is { AttributeProvider: PropertyInfo propertyInfo })
470470
{
471471
// Apply comments from the property
472472
if (XmlCommentCache.Cache.TryGetValue(DocumentationCommentIdHelper.NormalizeDocId(propertyInfo.CreateDocumentationId()), out var propertyComment))

src/OpenApi/test/Microsoft.AspNetCore.OpenApi.SourceGenerators.Tests/snapshots/SchemaTests.SupportsXmlCommentsOnSchemas#OpenApiXmlCommentSupport.generated.verified.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -479,10 +479,10 @@ public Task TransformAsync(OpenApiSchema schema, OpenApiSchemaTransformerContext
479479
}
480480
}
481481

482-
var isPropertyInlinedSchema = schema.Metadata is null
482+
var isInlinedSchema = schema.Metadata is null
483483
|| !schema.Metadata.TryGetValue("x-schema-id", out var schemaId)
484484
|| string.IsNullOrEmpty(schemaId as string);
485-
if (isPropertyInlinedSchema && context.JsonPropertyInfo is { AttributeProvider: PropertyInfo propertyInfo })
485+
if (isInlinedSchema && context.JsonPropertyInfo is { AttributeProvider: PropertyInfo propertyInfo })
486486
{
487487
// Apply comments from the property
488488
if (XmlCommentCache.Cache.TryGetValue(DocumentationCommentIdHelper.NormalizeDocId(propertyInfo.CreateDocumentationId()), out var propertyComment))

src/OpenApi/test/Microsoft.AspNetCore.OpenApi.SourceGenerators.Tests/snapshots/SchemaTests.XmlCommentsOnPropertiesShouldNotApplyToReferencedSchemas#OpenApiXmlCommentSupport.generated.verified.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -450,10 +450,10 @@ public Task TransformAsync(OpenApiSchema schema, OpenApiSchemaTransformerContext
450450
}
451451
}
452452

453-
var isPropertyInlinedSchema = schema.Metadata is null
453+
var isInlinedSchema = schema.Metadata is null
454454
|| !schema.Metadata.TryGetValue("x-schema-id", out var schemaId)
455455
|| string.IsNullOrEmpty(schemaId as string);
456-
if (isPropertyInlinedSchema && context.JsonPropertyInfo is { AttributeProvider: PropertyInfo propertyInfo })
456+
if (isInlinedSchema && context.JsonPropertyInfo is { AttributeProvider: PropertyInfo propertyInfo })
457457
{
458458
// Apply comments from the property
459459
if (XmlCommentCache.Cache.TryGetValue(DocumentationCommentIdHelper.NormalizeDocId(propertyInfo.CreateDocumentationId()), out var propertyComment))

src/OpenApi/test/Microsoft.AspNetCore.OpenApi.SourceGenerators.Tests/snapshots/XmlCommentDocumentationIdTests.CanMergeXmlCommentsWithDifferentDocumentationIdFormats#OpenApiXmlCommentSupport.generated.verified.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -442,10 +442,10 @@ public Task TransformAsync(OpenApiSchema schema, OpenApiSchemaTransformerContext
442442
}
443443
}
444444

445-
var isPropertyInlinedSchema = schema.Metadata is null
445+
var isInlinedSchema = schema.Metadata is null
446446
|| !schema.Metadata.TryGetValue("x-schema-id", out var schemaId)
447447
|| string.IsNullOrEmpty(schemaId as string);
448-
if (isPropertyInlinedSchema && context.JsonPropertyInfo is { AttributeProvider: PropertyInfo propertyInfo })
448+
if (isInlinedSchema && context.JsonPropertyInfo is { AttributeProvider: PropertyInfo propertyInfo })
449449
{
450450
// Apply comments from the property
451451
if (XmlCommentCache.Cache.TryGetValue(DocumentationCommentIdHelper.NormalizeDocId(propertyInfo.CreateDocumentationId()), out var propertyComment))

0 commit comments

Comments
 (0)