Skip to content

minLength for non string type #17

Closed
@alzeih

Description

When a property has mutliple allowed types (eg: string and null), but some of the validator options only apply to one of the types (eg: when it is a string), they get checked anyway, eg:

    "my_field" => {
      "type" => ["string", "null"],
      "required" => true,
      "minLength" => 1,
    }, 

will not validate when my_field is null.

I check in with the google group about this: http://groups.google.com/group/json-schema/browse_thread/thread/bc4bc01811d21bea/c2032f62b159d6eb .

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