brandur / json_schema

A JSON Schema V4 and Hyperschema V4 parser and validator.
MIT License
230 stars 45 forks source link

Expand a schema that is _just_ a reference #73

Closed brandur closed 7 years ago

brandur commented 7 years ago

The current reference expander does a pretty good job of expanding references that exist as subschemas in the schema, but fails to expand a schema that is just a JSON reference and nothing else.

This adds some code to short circuit the expansion mechanism if we detect a simple JSON reference and nothing else.