diff options
-rw-r--r-- | lib/mix/pleroma.ex | 3 | ||||
-rw-r--r-- | lib/mix/tasks/pleroma/database.ex | 6 |
2 files changed, 3 insertions, 6 deletions
diff --git a/lib/mix/pleroma.ex b/lib/mix/pleroma.ex index 0bebe4d54..def050d48 100644 --- a/lib/mix/pleroma.ex +++ b/lib/mix/pleroma.ex @@ -42,7 +42,8 @@ defmodule Mix.Pleroma do Pleroma.Repo, Supervisor.child_spec({Task, &Pleroma.Config.Environment.load_and_update/0}, id: :update_env - ) + ), + Pleroma.Web.Endpoint ] ++ additional_childs children = diff --git a/lib/mix/tasks/pleroma/database.ex b/lib/mix/tasks/pleroma/database.ex index ff47e9813..a01c36ece 100644 --- a/lib/mix/tasks/pleroma/database.ex +++ b/lib/mix/tasks/pleroma/database.ex @@ -83,11 +83,7 @@ defmodule Mix.Tasks.Pleroma.Database do ), where: o.inserted_at < ^time_deadline, where: - fragment( - "split_part(?->>'actor', '/', 3) != ?", - o.data, - ^Pleroma.Config.get([Pleroma.Web.Endpoint, :url, :host]) - ) + fragment("split_part(?->>'actor', '/', 3) != ?", o.data, ^Pleroma.Web.Endpoint.host()) ) |> Repo.delete_all(timeout: :infinity) |