Sha256: ec4c6b2b7a7ff7f0c06946475839c4e0704e71057cf7e79b2b7f55c1f0be438c
Contents?: true
Size: 783 Bytes
Versions: 2
Compression:
Stored size: 783 Bytes
Contents
class CreateFederailsActors < ActiveRecord::Migration[7.0] def change create_table :federails_actors do |t| t.string :name t.string :federated_url t.string :username t.string :server t.string :inbox_url t.string :outbox_url t.string :followers_url t.string :followings_url t.string :profile_url t.references :user, null: true, foreign_key: { to_table: Federails.configuration.user_table } t.timestamps t.index :federated_url, unique: true end remove_foreign_key :federails_actors, :users if foreign_key_exists?(:federails_actors, :users) remove_index :federails_actors, :user_id add_index :federails_actors, :user_id, unique: true add_foreign_key :federails_actors, :users end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
federails-0.2.0 | db/migrate/20200712133150_create_federails_actors.rb |
federails-0.1.0 | db/migrate/20200712133150_create_federails_actors.rb |