This repository has been archived on 2020-05-27. You can view files and clone it, but cannot push or open issues/pull-requests.
binaryattraction/schema/migrations/008_photo_indexes_migration.rb

14 lines
312 B
Ruby

class PhotoIndexesMigration < ActiveRecord::Migration
def self.up
add_index :photos, :votes_count
add_index :photos, :oneness
add_index :photos, :approved
end
def self.down
remove_index :photos, :votes_count
remove_index :photos, :oneness
remove_index :photos, :approved
end
end