Skip to content

Open source, privacy-first web analytics. Lightweight, cookie-free Google Analytics alternative. Self-hosted or cloud.

308 B
Raw Blame
defmodule Plausible.Repo.Migrations.AddNameToSharedLinks do
  use Ecto.Migration

  def change do
    alter table(:shared_links) do
      add :name, :string
    end

    execute "UPDATE shared_links SET name=slug"

    alter table(:shared_links) do
      modify :name, :string, null: false
    end
  end
end