Fork of Pleroma with site-specific changes and feature branches https://git.pleroma.social/pleroma/pleroma
Вы не можете выбрать более 25 тем Темы должны начинаться с буквы или цифры, могут содержать дефисы(-) и должны содержать не более 35 символов.

31 строка
776B

  1. defmodule Pleroma.Repo.Migrations.AddCorrectDMIndex do
  2. use Ecto.Migration
  3. @disable_ddl_transaction true
  4. def up do
  5. drop_if_exists(
  6. index(:activities, ["activity_visibility(actor, recipients, data)"],
  7. name: :activities_visibility_index
  8. )
  9. )
  10. create(
  11. index(:activities, ["activity_visibility(actor, recipients, data)", "id DESC NULLS LAST"],
  12. name: :activities_visibility_index,
  13. concurrently: true,
  14. where: "data->>'type' = 'Create'"
  15. )
  16. )
  17. end
  18. def down do
  19. drop_if_exists(
  20. index(:activities, ["activity_visibility(actor, recipients, data)", "id DESC"],
  21. name: :activities_visibility_index,
  22. concurrently: true,
  23. where: "data->>'type' = 'Create'"
  24. )
  25. )
  26. end
  27. end