Skip to content

Conversation

@ewaostrowska
Copy link
Contributor

Removes the root-level $ref from a schema when it has composition keywords (oneOf, allOf, or anyOf).

Checks if schema has composition - Verifies the schema contains oneOf, allOf, or anyOf arrays
Checks if root $ref matches a composed item - Compares the root $ref value against all $ref values within the composition arrays
Removes $ref if it matches - Sets the root $ref to null only if it matches one of the composed items

@ewaostrowska ewaostrowska merged commit 9f5bf1d into master Oct 21, 2025
5 checks passed
@ewaostrowska ewaostrowska deleted the issue-4959 branch October 21, 2025 09:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants