lib/xpose/exposed.rb in xpose-0.1.0 vs lib/xpose/exposed.rb in xpose-0.1.1

- old
+ new

@@ -44,17 +44,17 @@ v end end def infer_collection - klass.send(scope) + klass.send(conf.scope) end def infer_record source = if instance.respond_to?(conf.pluralized_name) ->{ instance.send(conf.pluralized_name) } else - ->{ klass.send(scope) } + ->{ klass.send(conf.scope) } end if instance.respond_to?(:params) && instance.params.has_key?(:id) source.call.find(instance.params[:id]) else source.call.new(params)