gitlab-org--gitlab-foss/db/migrate/20210701111627_add_upvotes_count_to_issues.rb

16 lines
326 B
Ruby
Raw Normal View History

# frozen_string_literal: true
class AddUpvotesCountToIssues < ActiveRecord::Migration[6.1]
include Gitlab::Database::MigrationHelpers
def up
with_lock_retries do
add_column :issues, :upvotes_count, :integer, default: 0, null: false
end
end
def down
remove_column :issues, :upvotes_count
end
end