summaryrefslogtreecommitdiff
path: root/priv
diff options
context:
space:
mode:
Diffstat (limited to 'priv')
-rw-r--r--priv/repo/migrations/20200703101031_add_chat_acceptance_to_users.exs17
-rw-r--r--priv/static/schemas/litepub-0.1.jsonld1
2 files changed, 18 insertions, 0 deletions
diff --git a/priv/repo/migrations/20200703101031_add_chat_acceptance_to_users.exs b/priv/repo/migrations/20200703101031_add_chat_acceptance_to_users.exs
new file mode 100644
index 000000000..8dfda89f1
--- /dev/null
+++ b/priv/repo/migrations/20200703101031_add_chat_acceptance_to_users.exs
@@ -0,0 +1,17 @@
+defmodule Pleroma.Repo.Migrations.AddChatAcceptanceToUsers do
+ use Ecto.Migration
+
+ def up do
+ alter table(:users) do
+ add(:accepts_chat_messages, :boolean, nullable: true)
+ end
+
+ execute("update users set accepts_chat_messages = true where local = true")
+ end
+
+ def down do
+ alter table(:users) do
+ remove(:accepts_chat_messages)
+ end
+ end
+end
diff --git a/priv/static/schemas/litepub-0.1.jsonld b/priv/static/schemas/litepub-0.1.jsonld
index 7cc3fee40..e7722cf72 100644
--- a/priv/static/schemas/litepub-0.1.jsonld
+++ b/priv/static/schemas/litepub-0.1.jsonld
@@ -13,6 +13,7 @@
},
"discoverable": "toot:discoverable",
"manuallyApprovesFollowers": "as:manuallyApprovesFollowers",
+ "capabilities": "litepub:capabilities",
"ostatus": "http://ostatus.org#",
"schema": "http://schema.org#",
"toot": "http://joinmastodon.org/ns#",