In relation to: litixsoft/lx-mongodb#1 (comment)
I did further tests and I noticed:
- Capitals are not respected for nested JSON fields, weather they are
required or not
- I have put all 3 fields of
location to be required (here: https://github.com/litixsoft/lx-valid/blob/master/test/revalidator.spec.js#L967-L984), and I was still capable to pass just some of them (one or two of them, but not whole 3), and that would be validated as true. This is obviously wrong.
So, it seems that for the nested field not only that capital letter check does not work, but schema check does not work neither! I.e. we are capable to pass incomplete JSON, and that would validate as true.
In relation to: litixsoft/lx-mongodb#1 (comment)
I did further tests and I noticed:
requiredor notlocationto berequired(here: https://github.com/litixsoft/lx-valid/blob/master/test/revalidator.spec.js#L967-L984), and I was still capable to pass just some of them (one or two of them, but not whole 3), and that would be validated astrue. This is obviously wrong.So, it seems that for the nested field not only that capital letter check does not work, but schema check does not work neither! I.e. we are capable to pass incomplete JSON, and that would validate as
true.