parent
67c1de097c
commit
8893575db7
@ -1,6 +1,7 @@
|
||||
class UniqIndexOnCollections < ActiveRecord::Migration[5.2]
|
||||
def change
|
||||
remove_index :collections, [:container_type, :container_id]
|
||||
add_index :collections, [:container_type, :container_id], unique: true
|
||||
add_index :collections, [:container_type, :container_id]
|
||||
add_index :collections, [:user_id, :container_type, :container_id], unique: true
|
||||
end
|
||||
end
|
Loading…
Reference in new issue