Sha256: 7336e14f95ea69cac16ea30b90bbe7fbb30d05a441b6edcf0b75f1012f3fb062
Contents?: true
Size: 487 Bytes
Versions: 48
Compression:
Stored size: 487 Bytes
Contents
# frozen_string_literal: true class AddFollowableCounterCacheToProposals < ActiveRecord::Migration[5.2] def change add_column :decidim_proposals_proposals, :follows_count, :integer, null: false, default: 0, index: true reversible do |dir| dir.up do Decidim::Proposals::Proposal.reset_column_information Decidim::Proposals::Proposal.find_each do |record| record.class.reset_counters(record.id, :follows) end end end end end
Version data entries
48 entries across 48 versions & 1 rubygems