forked from mirrors/akkoma
Actually make index unique.
This commit is contained in:
parent
2f093db051
commit
b9d1fc05b2
1 changed files with 10 additions and 0 deletions
|
@ -0,0 +1,10 @@
|
|||
defmodule Pleroma.Repo.Migrations.AddIdContraintsToActivitiesAndObjectsPartTwo do
|
||||
use Ecto.Migration
|
||||
|
||||
def change do
|
||||
drop index(:objects, ["(data->>\"id\")"], name: :objects_unique_apid_index)
|
||||
drop index(:activities, ["(data->>\"id\")"], name: :activities_unique_apid_index)
|
||||
create unique_index(:objects, ["(data->>'id')"], name: :objects_unique_apid_index)
|
||||
create unique_index(:activities, ["(data->>'id')"], name: :activities_unique_apid_index)
|
||||
end
|
||||
end
|
Loading…
Reference in a new issue