class AddUserCountersToDomainUsers < ActiveRecord::Migration[7.2]
  def up
    add_column :domain_users,
               :user_post_creations_count,
               :integer,
               default: nil,
               null: true
    add_column :domain_users,
               :user_post_favs_count,
               :integer,
               default: nil,
               null: true
    add_column :domain_users,
               :user_user_follows_from_count,
               :integer,
               default: nil,
               null: true
    add_column :domain_users,
               :user_user_follows_to_count,
               :integer,
               default: nil,
               null: true
  end

  def down
    remove_column :domain_users, :user_post_creations_count
    remove_column :domain_users, :user_post_favs_count
    remove_column :domain_users, :user_user_follows_from_count
    remove_column :domain_users, :user_user_follows_to_count
  end
end
