Fix `preview_cards_statuses_pkey` not being reindexed concurrently (#26384)

th-downstream
Claire 1 year ago committed by GitHub
parent 5b7c925573
commit 64e9f2e65a

@ -18,7 +18,7 @@ class AddUniqueIndexOnPreviewCardsStatuses < ActiveRecord::Migration[6.1]
def deduplicate_and_reindex!
deduplicate_preview_cards!
safety_assured { execute 'REINDEX INDEX preview_cards_statuses_pkey' }
safety_assured { execute 'REINDEX INDEX CONCURRENTLY preview_cards_statuses_pkey' }
rescue ActiveRecord::RecordNotUnique
retry
end

Loading…
Cancel
Save