-
Notifications
You must be signed in to change notification settings - Fork 279
Fixes cloning of JsonNode objects
#1616
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
| Summary = example?.Summary ?? Summary; | ||
| Description = example?.Description ?? Description; | ||
| Value = example?.Value ?? JsonNodeCloneHelper.Clone(example?.Value); | ||
| Value = example?.Value != null ? JsonNodeCloneHelper.Clone(example.Value) : null; |
Check warning
Code scanning / CodeQL
Virtual call in constructor or destructor
| ExternalValue = example?.ExternalValue ?? ExternalValue; | ||
| Extensions = example?.Extensions != null ? new Dictionary<string, IOpenApiExtension>(example.Extensions) : null; | ||
| Reference = example?.Reference != null ? new(example?.Reference) : null; | ||
| Reference = example?.Reference != null ? new(example.Reference) : null; |
Check warning
Code scanning / CodeQL
Virtual call in constructor or destructor
| AllowReserved = header?.AllowReserved ?? AllowReserved; | ||
| Schema = header?.Schema != null ? JsonNodeCloneHelper.CloneJsonSchema(header?.Schema) : null; | ||
| Example = header?.Example != null ? JsonNodeCloneHelper.Clone(header?.Example) : null; | ||
| Schema = header?.Schema != null ? JsonNodeCloneHelper.CloneJsonSchema(header.Schema) : null; |
Check warning
Code scanning / CodeQL
Virtual call in constructor or destructor
| Schema = header?.Schema != null ? JsonNodeCloneHelper.CloneJsonSchema(header?.Schema) : null; | ||
| Example = header?.Example != null ? JsonNodeCloneHelper.Clone(header?.Example) : null; | ||
| Schema = header?.Schema != null ? JsonNodeCloneHelper.CloneJsonSchema(header.Schema) : null; | ||
| Example = header?.Example != null ? JsonNodeCloneHelper.Clone(header.Example) : null; |
Check warning
Code scanning / CodeQL
Virtual call in constructor or destructor
| { | ||
| _schema = JsonNodeCloneHelper.CloneJsonSchema(mediaType?.Schema); | ||
| Example = JsonNodeCloneHelper.Clone(mediaType?.Example); | ||
| Schema = mediaType?.Schema != null ? JsonNodeCloneHelper.CloneJsonSchema(mediaType.Schema) : null; |
Check warning
Code scanning / CodeQL
Virtual call in constructor or destructor
| Explode = parameter?.Explode ?? Explode; | ||
| AllowReserved = parameter?.AllowReserved ?? AllowReserved; | ||
| Schema = parameter?.Schema != null ? JsonNodeCloneHelper.CloneJsonSchema(parameter?.Schema) : null; | ||
| Schema = parameter?.Schema != null ? JsonNodeCloneHelper.CloneJsonSchema(parameter.Schema) : null; |
Check warning
Code scanning / CodeQL
Virtual call in constructor or destructor
| Schema = parameter?.Schema != null ? JsonNodeCloneHelper.CloneJsonSchema(parameter.Schema) : null; | ||
| Examples = parameter?.Examples != null ? new Dictionary<string, OpenApiExample>(parameter.Examples) : null; | ||
| Example = parameter?.Example != null ? JsonNodeCloneHelper.Clone(parameter?.Example) : null; | ||
| Example = parameter?.Example != null ? JsonNodeCloneHelper.Clone(parameter.Example) : null; |
Check warning
Code scanning / CodeQL
Virtual call in constructor or destructor
... and other nit fixes