mirror of
https://akkoma.dev/AkkomaGang/akkoma.git
synced 2024-11-10 10:09:02 +00:00
Migrations: Add accepts_chat_messages
to users.
This commit is contained in:
parent
fd5ad99ace
commit
8ad166e8e3
|
@ -0,0 +1,12 @@
|
|||
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
|
Loading…
Reference in a new issue