1 # Pleroma: A lightweight social networking server
2 # Copyright © 2017-2022 Pleroma Authors <https://pleroma.social/>
3 # SPDX-License-Identifier: AGPL-3.0-only
5 defmodule Pleroma.Repo.Migrations.DropUsersFollowing do
8 # had to disable these to be able to restore `following` index concurrently
9 # https://hexdocs.pm/ecto_sql/Ecto.Migration.html#index/3-adding-dropping-indexes-concurrently
10 @disable_ddl_transaction true
11 @disable_migration_lock true
14 drop(index(:users, [:following], concurrently: true, using: :gin))
16 alter table(:users) do
17 remove(:following, {:array, :string}, default: [])