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

lolsob-rspec
Claire 2023-08-08 11:41:53 +02:00 committed by GitHub
parent 5b7c925573
commit 64e9f2e65a
1 changed files with 1 additions and 1 deletions

View File

@ -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