Skip to content

nesting anyOf under allOf is broken #25

@jonasfj

Description

@jonasfj

I can't get this to work:

let v = themis.validator({
    id: 'test',
    allOf: [
      {
        anyOf: [
          {
            required: ['test']
          }
        ]
      }
    ]
});

let report = v({
    test: 2
}, 'test'); // gives report.valid = false

Works fine in other JSON validators... ironic since you're actually using this pattern in the feature to validate schemas... which is inherently broken as a result.. e.g. force_additional: true doesn't work in options.

However, the big issue here is probably that validation is broken...

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions