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

Avoid empty instancePath when propertyNames is violated #199

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

Commits on Oct 30, 2024

  1. Avoid empty instancePath when propertyNames is violated.

    This makes `_validate` take an `Instance` object instead of dynamic.
    And instead forces the callers to convert any values to `Instance`
    objects.
    
    This is probably a good idea because:
     * Caller is the only one who can construct the `instancePath`.
     * It avoids a lot of unnecessary `instance is! Instance` checks.
    
    Fixing this it was discovered that `propertyNames` errors were reported
    with an empty `instancePath`. Which could cause confusion for anyone
    trying to display the error.
    jonasfj committed Oct 30, 2024
    Configuration menu
    Copy the full SHA
    31a345c View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    d6b49b2 View commit details
    Browse the repository at this point in the history