mirror of
https://github.com/glitch-soc/mastodon.git
synced 2025-12-15 16:59:41 +00:00
Fix Rails/BulkChangeTable cop (#26890)
This commit is contained in:
@@ -2,8 +2,12 @@
|
||||
|
||||
class AddLanguageToPreviewCards < ActiveRecord::Migration[6.1]
|
||||
def change
|
||||
add_column :preview_cards, :language, :string
|
||||
add_column :preview_cards, :max_score, :float
|
||||
add_column :preview_cards, :max_score_at, :datetime
|
||||
safety_assured do
|
||||
change_table(:preview_cards, bulk: true) do |t|
|
||||
t.column :language, :string
|
||||
t.column :max_score, :float
|
||||
t.column :max_score_at, :datetime
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user