mirror of https://github.com/apache/lucene.git
Remove creating new Solr::Document in #add, as AddDocument.new already does this. This change allows a SolrDocument to be passed to #add/#update, instead of just a Hash
git-svn-id: https://svn.apache.org/repos/asf/lucene/solr/trunk@498436 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
b9f5817c3c
commit
18e95b18a7
|
@ -46,7 +46,6 @@ module Solr
|
||||||
# true/false will be returned to designate success/failure
|
# true/false will be returned to designate success/failure
|
||||||
|
|
||||||
def add(doc)
|
def add(doc)
|
||||||
doc = Solr::Document.new(doc)
|
|
||||||
request = Solr::Request::AddDocument.new(doc)
|
request = Solr::Request::AddDocument.new(doc)
|
||||||
response = send(request)
|
response = send(request)
|
||||||
commit if @autocommit
|
commit if @autocommit
|
||||||
|
|
Loading…
Reference in New Issue