Skip to content

Commit

Permalink
Fix published migration
Browse files Browse the repository at this point in the history
  • Loading branch information
marcoroth committed Aug 16, 2024
1 parent e69d4e5 commit 168d653
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion db/migrate/20240816074626_add_status_to_topic.rb
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,6 @@ def change
add_column :topics, :status, :string, null: false, default: "pending"
add_index :topics, :status

Topic.published.update_all(status: "approved")
Topic.where(published: true).update_all(status: "approved")
end
end

0 comments on commit 168d653

Please sign in to comment.