You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 

8 lines
330 B

class AddCreatedByApplicationIdToUsers < ActiveRecord::Migration[5.2]
disable_ddl_transaction!
def change
add_reference :users, :created_by_application, foreign_key: { to_table: 'oauth_applications', on_delete: :nullify }, index: false
add_index :users, :created_by_application_id, algorithm: :concurrently
end
end