lib/ahc_helper.rb in ahc-0.3.3 vs lib/ahc_helper.rb in ahc-0.3.4
- old
+ new
@@ -26,10 +26,10 @@
@data ||= {}
case params[:action]
when 'show'
@data['resource'] = resource
when 'index'
- @data['resources'] = resources
+ @data['resources'] = resources[0]
when 'create', 'update'
params[:format] = 'json'
if resource.valid?
@data['resource'] = resource
else