Skip to content

Commit cd4d411

Browse files
Update src/Microsoft.OpenApi/Reader/V31/OpenApiSchemaDeserializer.cs
Co-authored-by: Vincent Biret <[email protected]>
1 parent 42a5a2d commit cd4d411

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Microsoft.OpenApi/Reader/V31/OpenApiSchemaDeserializer.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -399,7 +399,7 @@ public static IOpenApiSchema LoadSchema(ParseNode node, OpenApiDocument hostDocu
399399
schema.Extensions.Remove(OpenApiConstants.NullableExtension);
400400
}
401401

402-
if (identifier is not null && hostDocument.Workspace is not null)
402+
if (!string.IsNullOrEmpty(identifier) && hostDocument.Workspace is not null)
403403
{
404404
// register the schema in our registry using the identifier's URL
405405
hostDocument.Workspace.RegisterComponentForDocument(hostDocument, schema, identifier);

0 commit comments

Comments
 (0)