Let's say I have a model:
class Foo {
int myValue;
}
And a json file:
Morph will happily deserialize this without errors, even though I got the name of the field wrong ("myvalue" versus "myValue"). It will create a Foo with myValue set to 0. This can be confusing. An option to error on unrecognized fields would let me catch this mistake sooner.
Let's say I have a model:
And a json file:
Morph will happily deserialize this without errors, even though I got the name of the field wrong ("myvalue" versus "myValue"). It will create a Foo with
myValueset to 0. This can be confusing. An option to error on unrecognized fields would let me catch this mistake sooner.