lib/hyper_resource/adapter/hal_json.rb in aptible-resource-0.2.7 vs lib/hyper_resource/adapter/hal_json.rb in aptible-resource-0.2.8
- old
+ new
@@ -48,9 +48,10 @@
if collection.is_a? Hash
r = rc.new(:root => rsrc.root,
:headers => rsrc.headers,
:namespace => rsrc.namespace)
r.body = collection
+ r = classify(collection, r)
objs[name] = apply(collection, r)
else
objs[name] = collection.map do |obj|
r = rc.new(:root => rsrc.root,
:headers => rsrc.headers,