diff --git a/Classes/JSONAPIResourceParser.m b/Classes/JSONAPIResourceParser.m index f3d6d89..c737a02 100644 --- a/Classes/JSONAPIResourceParser.m +++ b/Classes/JSONAPIResourceParser.m @@ -121,8 +121,8 @@ + (NSDictionary*)dictionaryFor:(NSObject *)resource { [dictionaryArray addObject:[self link:valueElement from:resource withKey:[property jsonName]]]; } - [linkage setValue:dictionaryArray forKey:[property jsonName]]; - + NSDictionary *dataDictionary = @{@"data" : dictionaryArray}; + [linkage setValue:dataDictionary forKey:[property jsonName]]; } else { NSFormatter *format = [property formatter]; @@ -366,10 +366,15 @@ + (NSDictionary*)link:(NSObject *)resource from:(NSObject