brutusin/json-forms

Validation failure of enum value

Opened this issue · 1 comments

After calling the render method with the following schema and initial data, calling the validate method returns an incorrect result of true.

schema:
{
"type": "object",
"properties": {
"id": {
"type": "string",
"enum": ["good"]
}
}
}

Data to be validated:

{
"id": "bad"
}

{
"type": "object",
"properties": {
"id": {
"type": "string",
"enum": ["good", "bad"]
}
}
}