[Groonga-commit] droonga/drndump at 4c8ba98 [master] Use client options given as a part of options for the constructor

Back to archive index

YUKI Hiroshi null+****@clear*****
Wed Apr 15 19:53:18 JST 2015


YUKI Hiroshi	2015-04-15 19:53:18 +0900 (Wed, 15 Apr 2015)

  New Revision: 4c8ba98f46df03e426ea8f56a085d7e646d98ff5
  https://github.com/droonga/drndump/commit/4c8ba98f46df03e426ea8f56a085d7e646d98ff5

  Message:
    Use client options given as a part of options for the constructor

  Modified files:
    lib/drndump/dump_client.rb

  Modified: lib/drndump/dump_client.rb (+3 -1)
===================================================================
--- lib/drndump/dump_client.rb    2015-04-15 18:36:57 +0900 (35f282d)
+++ lib/drndump/dump_client.rb    2015-04-15 19:53:18 +0900 (b7f313f)
@@ -34,6 +34,8 @@ module Drndump
       @receiver_host = params[:receiver_host]
       @receiver_port = params[:receiver_port]
 
+      @client_options = params[:client_options]
+
       @error_message = nil
 
       @on_finish = nil
@@ -42,7 +44,7 @@ module Drndump
     end
 
     def run(options={}, &block)
-      extra_client_options = options[:client_options] || {}
+      extra_client_options = options[:client_options] || @client_options || {}
       client = Droonga::Client.new(client_options.merge(extra_client_options))
       client.on_error = lambda do |error|
         on_error(error)
-------------- next part --------------
HTML����������������������������...
Descargar 



More information about the Groonga-commit mailing list
Back to archive index