Commit 5259f731 by Ivan Lan

fix; fix arguments

parent be9896f6
...@@ -136,7 +136,7 @@ module TalltyImportExport ...@@ -136,7 +136,7 @@ module TalltyImportExport
end end
def process_options(options) def process_options(options)
options = import_options.merge(options).with_indifferent_access options = import_options.merge(options).with_indifferent_access.symbolize_keys
@headers = options.delete(:headers) || import_headers(**options) @headers = options.delete(:headers) || import_headers(**options)
@primary_keys = options.delete(:primary_keys) || @headers.map { |header| header[:primary_key] ? header[:key].to_sym : nil }.compact @primary_keys = options.delete(:primary_keys) || @headers.map { |header| header[:primary_key] ? header[:key].to_sym : nil }.compact
@skip_keys = options.delete(:skip_keys) || @headers.map { |header| header[:skip] ? header[:key].to_sym : nil }.compact @skip_keys = options.delete(:skip_keys) || @headers.map { |header| header[:skip] ? header[:key].to_sym : nil }.compact
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment