-
Notifications
You must be signed in to change notification settings - Fork 1
Open
Labels
bugSomething isn't workingSomething isn't working
Milestone
Description
If null is provided as data, then the JSON schema validation will fail, if we don't allow type of null
for optional references. The reference object must allow null
to pass JSON schema validation, which is wrong.
The shorthand syntax of:
{
"shorthand": true,
"schema": {
"customerId": "/Customer/CustomerId",
"externalId?": "/Acme/ExternalId"
}
}
should be translated into
{
"type": "object",
"properties": {
"customerId": {
"$ref": "#/definitions/Customer/CustomerId",
"namespace": "/Customer"
},
"externalId": {
"oneOf": [
{"type": "null"},
{"$ref": "#/definitions/Acme/ExternalId"}
],
"namespace": "/Acme"
}
},
"required": [
"customerId"
],
"additionalProperties": false
}
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working