joannangx/visionaria_app

View on GitHub
db/migrate/20161102073550_create_likes.rb

Summary

Maintainability
A
35 mins
Test Coverage
class CreateLikes < ActiveRecord::Migration
  def change
    create_table :likes do |t|
      t.references :post, index: true, foreign_key: true
      t.references :tagged_post, index: true, foreign_key: true
      t.references :user, index: true, foreign_key: true
      t.timestamps null: false
    end
  end
end