Fork of Pleroma with site-specific changes and feature branches https://git.pleroma.social/pleroma/pleroma
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

20 lines
515B

  1. defmodule Pleroma.Repo.Migrations.SetNotNullForRegistrations do
  2. use Ecto.Migration
  3. # modify/3 function will require index recreation, so using execute/1 instead
  4. def up do
  5. execute("ALTER TABLE registrations
  6. ALTER COLUMN provider SET NOT NULL,
  7. ALTER COLUMN uid SET NOT NULL,
  8. ALTER COLUMN info SET NOT NULL")
  9. end
  10. def down do
  11. execute("ALTER TABLE registrations
  12. ALTER COLUMN provider DROP NOT NULL,
  13. ALTER COLUMN uid DROP NOT NULL,
  14. ALTER COLUMN info DROP NOT NULL")
  15. end
  16. end