umco / umbraco-ditto

Ditto - the friendly view-model mapper for Umbraco
http://our.umbraco.org/projects/developer-tools/ditto
MIT License
79 stars 33 forks source link

Setting default values for ValueType objects #171

Closed leekelleher closed 8 years ago

leekelleher commented 8 years ago

If a POCO has property that is a ValueType, (e.g. bool, int, etc), but Ditto can't get a value for it, then we try to set the value as null, which throws an exception.

See corresponding unit-test in commit 6f835d8c0a64c4aeba79df50edcfd30d9baf939c.

leekelleher commented 8 years ago

@mattbrailsford Just to note, this is in the "release-0.9.0" branch. No pressure to look into this tonight, I can take a look later (or tomorrow).

mattbrailsford commented 8 years ago

Sorted :)

leekelleher commented 8 years ago

Awesomeness, thanks Matt!