2017-08-14 11:56:23 +00:00
|
|
|
class Sequencer
|
|
|
|
class Unit
|
|
|
|
module Import
|
|
|
|
module Common
|
|
|
|
module User
|
|
|
|
module Attributes
|
|
|
|
class Downcase < Sequencer::Unit::Base
|
|
|
|
prepend ::Sequencer::Unit::Import::Common::Model::Mixin::SkipOnSkippedInstance
|
|
|
|
|
|
|
|
uses :mapped
|
|
|
|
|
|
|
|
def process
|
2017-11-23 08:09:44 +00:00
|
|
|
%i[login email].each do |attribute|
|
2017-08-14 11:56:23 +00:00
|
|
|
next if mapped[attribute].blank?
|
|
|
|
mapped[attribute].downcase!
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|