20180108000001_change_exchange_external_sync_identifier.rb 462 B

123456789101112131415
  1. # Copyright (C) 2012-2024 Zammad Foundation, https://zammad-foundation.org/
  2. class ChangeExchangeExternalSyncIdentifier < ActiveRecord::Migration[5.1]
  3. def up
  4. # return if it's a new setup to avoid running the migration
  5. return if !Setting.exists?(name: 'system_init_done')
  6. ExternalSync.where(
  7. source: 'EWS::FolderContact'
  8. ).update_all( # rubocop:disable Rails/SkipsModelValidations
  9. source: 'Exchange::FolderContact'
  10. )
  11. end
  12. end