lib/searchkick/logging.rb in searchkick-0.8.7 vs lib/searchkick/logging.rb in searchkick-0.9.0
- old
+ new
@@ -75,10 +75,10 @@
type = payload[:query][:type]
index = payload[:query][:index].is_a?(Array) ? payload[:query][:index].join(",") : payload[:query][:index]
# no easy way to tell which host the client will use
host = Searchkick.client.transport.hosts.first
- debug " #{color(name, YELLOW, true)} curl #{host[:protocol]}://#{host[:host]}:#{host[:port]}/#{CGI.escape(index)}#{type ? "/#{type.map{|t| CGI.escape(t) }.join(",")}" : ""}/_search?pretty -d '#{payload[:query][:body].to_json}'"
+ debug " #{color(name, YELLOW, true)} curl #{host[:protocol]}://#{host[:host]}:#{host[:port]}/#{CGI.escape(index)}#{type ? "/#{type.map { |t| CGI.escape(t) }.join(',')}" : ''}/_search?pretty -d '#{payload[:query][:body].to_json}'"
end
def request(event)
self.class.runtime += event.duration
return unless logger.debug?