20211028094326_issue_3245_office_365_microsoft_rename.rb 460 B

123456789101112131415
  1. # Copyright (C) 2012-2023 Zammad Foundation, https://zammad-foundation.org/
  2. class Issue3245Office365MicrosoftRename < ActiveRecord::Migration[6.0]
  3. def up
  4. return if !Setting.exists?(name: 'system_init_done')
  5. setting = Setting.find_by name: 'auth_microsoft_office365'
  6. setting.preferences[:title_i18n][0] = 'Microsoft'
  7. setting.preferences[:description_i18n][0] = 'Microsoft'
  8. setting.save!
  9. rescue => e
  10. Rails.logger.error e
  11. end
  12. end