X-Git-Url: https://git.squeep.com/?a=blobdiff_plain;f=priv%2Frepo%2Fmigrations%2F20170415141210_add_unique_index_to_email_and_nickname.exs;h=b18c67dcb78471355de94dcbbcec229862b0676a;hb=af6d01ec93a07cd896bc4f0a2c2cf437c6fd51fc;hp=361ca04daf6297ae12f5579c5102dd8b0991930c;hpb=ce1eef9c989f0387168b48f6f61a4c1f84b3f5b5;p=akkoma diff --git a/priv/repo/migrations/20170415141210_add_unique_index_to_email_and_nickname.exs b/priv/repo/migrations/20170415141210_add_unique_index_to_email_and_nickname.exs index 361ca04da..b18c67dcb 100644 --- a/priv/repo/migrations/20170415141210_add_unique_index_to_email_and_nickname.exs +++ b/priv/repo/migrations/20170415141210_add_unique_index_to_email_and_nickname.exs @@ -2,7 +2,7 @@ defmodule Pleroma.Repo.Migrations.AddUniqueIndexToEmailAndNickname do use Ecto.Migration def change do - create unique_index(:users, [:email]) - create unique_index(:users, [:nickname]) + create_if_not_exists(unique_index(:users, [:email])) + create_if_not_exists(unique_index(:users, [:nickname])) end end