downcase.rb 435 B

1234567891011121314151617
  1. # Copyright (C) 2012-2024 Zammad Foundation, https://zammad-foundation.org/
  2. class Sequencer::Unit::Import::Common::User::Attributes::Downcase < Sequencer::Unit::Base
  3. prepend ::Sequencer::Unit::Import::Common::Model::Mixin::Skip::Action
  4. skip_action :skipped, :failed
  5. uses :mapped
  6. def process
  7. %i[login email].each do |attribute|
  8. next if mapped[attribute].blank?
  9. mapped[attribute].downcase!
  10. end
  11. end
  12. end