lantanagroup / FHIR.js

Node.JS library for serializing/deserializing FHIR resources between JS/JSON and XML using various node.js XML libraries
Apache License 2.0
102 stars 29 forks source link

JSON Validator incorrectly allows quoted booleans and numbers #30

Open caistrop opened 4 years ago

caistrop commented 4 years ago

The JSON validator incorrectly allows quotes around boolean and numeric values. For example if you had a Patient resource with a property of ("active":"true") The Validator accepts the above json, however to be valid json, the "true" should be unquoted ("active" : true) The same happens for numbers ("multipleBirthInteger" : "2") will pass validation, but to be json conformant, it should be ("multipleBirthInteger" : 2)