I'm using MagicalRecord to pull a json file from my server. All my Objects load fine except for an equipment object. Here's the log of the JSON file
"Equipment":[
{
"equipmentID":1,
"equipmentName":"Barbell",
"equipmentDescription":"Barbell"
}
]
My Equipment class is a pretty basic setup
@property (nonatomic, retain) NSNumber * equipmentID;
@property (nonatomic, retain) NSString * equipmentName;
@property (nonatomic, retain) NSString * equipmentDescription;
In the data model, I have equipmentID as Integer 16. If I change it to Integer 64 then I get this error.
[__NSArrayM longLongValue]: unrecognized selector sent to instance
I don't understand what's the issue, the format is consistent with other objects in the same JSON file. The equipmentID is obviously an intValue and the Equipment class is setup as a NSNumber with equipmentID as an integer.
Any help? Is there a bug with Magical Record?
You need to write like,