Skip to content
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

Validation of oneOf depends on schema order #361

Merged
merged 2 commits into from
Dec 30, 2020
Merged

Validation of oneOf depends on schema order #361

merged 2 commits into from
Dec 30, 2020

Conversation

ennoruijters
Copy link
Contributor

Issue #295 appears to be caused when the validation of one element of a oneOf schema fails due to a failed 'required' block (setting ValidatorState.matchedNode to false), and a later schema succeeds without matching any 'properties' block (which would set ValidatorState.matchedNode to true).

I'm not familiar enough with the entire code to be sure that my fix is correct, but it fixes the reported testcase and I see no immediate problems.

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.

2 participants