lib/ecoportal/api/common/batch_operation.rb in ecoportal-api-0.3.0.pre1 vs lib/ecoportal/api/common/batch_operation.rb in ecoportal-api-0.3.0
- old
+ new
@@ -60,14 +60,13 @@
callback: block_given? && Proc.new
}
end
def upsert(doc)
- id = get_id(doc)
- external_id = get_external_id(doc)
- body = get_body(doc)
+ id = get_id(doc)
+ body = get_body(doc)
@operations << {
- path: @base_path + "/" + CGI::escape(external_id || id),
+ path: @base_path + "/" + CGI::escape(id),
method: "POST",
body: body,
callback: block_given? && Proc.new
}
end