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

Fix schema with “properties” and “additionalProperties” #80

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Commits on Sep 24, 2019

  1. Test schema with "properties" and "additionalProperties".

    Currently fails with "oops – TypeError: Attempted to assign to readonly property.".
    cwalther committed Sep 24, 2019
    Configuration menu
    Copy the full SHA
    4986ed0 View commit details
    Browse the repository at this point in the history
  2. Fix "oops – TypeError: Attempted to assign to readonly property."

    The error is encountered when rendering a schema containing both "properties" and "additionalProperties" and occurs because the "name" helper is invoked with Handlebars' nullContext, a read-only empty object.
    
    Checking for "additionalProperties" and then rendering "../additionalProperties" makes no sense. I'm not sure why this worked previously (apparently the parent context was the same as the current context at some point), it seems to have been broken in 7d17a0d where many dependencies were updated over several major versions.
    cwalther committed Sep 24, 2019
    Configuration menu
    Copy the full SHA
    fa2c34f View commit details
    Browse the repository at this point in the history