analytics/priv/repo/migrations/20190430140411_use_citext_for_email.exs

12 lines
236 B
Elixir
Raw Normal View History

2019-09-02 14:29:19 +03:00
defmodule Plausible.Repo.Migrations.UseCitextForEmail do
use Ecto.Migration
def change do
execute "CREATE EXTENSION IF NOT EXISTS citext;"
alter table(:users) do
modify :email, :citext, null: false
end
end
end