Class: SolidusImporter::Processors::Customer

Inherits:
Base
  • Object
show all
Defined in:
lib/solidus_importer/processors/customer.rb

Instance Method Summary collapse

Instance Method Details

#call(context) ⇒ Object



6
7
8
9
10
11
# File 'lib/solidus_importer/processors/customer.rb', line 6

def call(context)
  @data = context.fetch(:data)
  check_data

  context.merge!(user: process_user && persist_user)
end

#optionsObject



13
14
15
16
17
# File 'lib/solidus_importer/processors/customer.rb', line 13

def options
  @options ||= {
    password_method: ->(_user) { SecureRandom.alphanumeric(8) }
  }
end