mirror of
https://akkoma.dev/AkkomaGang/akkoma.git
synced 2024-11-11 02:28:45 +00:00
13 lines
356 B
Elixir
13 lines
356 B
Elixir
|
defmodule Pleroma.Repo.Migrations.AddChatAcceptanceToUsers do
|
||
|
use Ecto.Migration
|
||
|
|
||
|
def change do
|
||
|
alter table(:users) do
|
||
|
add(:accepts_chat_messages, :boolean, nullable: false, default: false)
|
||
|
end
|
||
|
|
||
|
# Looks stupid but makes the update much faster
|
||
|
execute("update users set accepts_chat_messages = local where local = true")
|
||
|
end
|
||
|
end
|