koumoul-dev / vuetify-jsonschema-form

Create beautiful and low-effort forms that output valid data. Published on npm as @koumoul/vjsf.
https://koumoul-dev.github.io/vuetify-jsonschema-form/latest/
MIT License
538 stars 154 forks source link

fix: handle null array in `initFromSchema()` #428

Closed mvandenburgh closed 4 months ago

mvandenburgh commented 4 months ago

Fixes #427

The initFromSchema() method assumes that an object with a type of "array" is always non-null and can be iterated over with Array.prototype.filter(). However, a nullable array is perfectly valid in a JSON Schema.

I think that's a correct summary of what's going wrong here, but I'm not familiar enough with the codebase to say for sure.

yarikoptic commented 4 months ago

FWIW: a quick review/merge/release (if possible) would be highly appreciated!

albanm commented 4 months ago

Released in 2.23.3.

yarikoptic commented 4 months ago

Thank you @albanm !