matthewcheok / Realm-JSON

A concise Mantle-like way of working with Realm and JSON.
MIT License
661 stars 129 forks source link

Unchecked NSNull condition for RLMArray #69

Open jrmybrault opened 8 years ago

jrmybrault commented 8 years ago

_mccreateObjectFromJSONDictionary crashes whenever var propertyClass is a subclass of RLMArray and var value is NSNull. There should be the same check that in the RLMObject case.

if (!value || [value isEqual:[NSNull null]]) {
    continue;
}

By the way, why testing (!value) in a if (value) condition block ? It seems kinda useless.

yuldong commented 8 years ago

i met this question too