Object: Add the ap_id column.

This commit is contained in:
lain 2019-10-07 18:06:48 +02:00
parent 93bdc55306
commit 51c1578780
2 changed files with 12 additions and 0 deletions

View File

@ -19,6 +19,7 @@ defmodule Pleroma.Object do
schema "objects" do schema "objects" do
field(:data, :map) field(:data, :map)
field(:ap_id, :string)
timestamps() timestamps()
end end

View File

@ -0,0 +1,11 @@
defmodule Pleroma.Repo.Migrations.AddApIdColumnToObjects do
use Ecto.Migration
def change do
alter table(:objects) do
add :ap_id, :string
end
create unique_index(:objects, [:ap_id], concurrently: true)
end
end