Add unique index and unique constraint check, uniqueness test fails
This commit is contained in:
parent
478a05b4c9
commit
6a150de3bd
3 changed files with 23 additions and 10 deletions
|
|
@ -7,6 +7,6 @@ defmodule Pleroma.Repo.Migrations.CreateThreadMutes do
|
|||
add :context, :string
|
||||
end
|
||||
|
||||
create index(:thread_mutes, [:user_id])
|
||||
create unique_index(:thread_mutes, [:user_id, :context], name: :unique_index)
|
||||
end
|
||||
end
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue