jeudi 4 septembre 2014

JSON: Allow null value in reference to object


Vote count:

0




How can i allow null values in reference to object?



{
"type" : "object",
"properties" : {
"foreign-key-field" : {
"type" : ["object", "null" ],
"$ref" : "object-schema.json"
},
},
"additionalProperties" : false
}


This is my schema, but it does not allow me to do that. it throws "Validation error: None is not of type u'object' (at [u'foreign-key-field'])" in validator.



asked 1 min ago







JSON: Allow null value in reference to object

Aucun commentaire:

Enregistrer un commentaire