summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMark Felder <feld@feld.me>2024-05-07 22:10:49 -0400
committerMark Felder <feld@feld.me>2024-05-07 22:10:49 -0400
commit37c35daba66b3534d8724266118053c11057f2b3 (patch)
tree91df4993b7c2ff48c4348f316126ede3d2dc196b
parent9b9a32bf74a87047b3c12b468f3351950c334995 (diff)
downloadpleroma-37c35daba66b3534d8724266118053c11057f2b3.tar.gz
pleroma-37c35daba66b3534d8724266118053c11057f2b3.zip
Credo
-rw-r--r--lib/pleroma/web/rich_media/backfill.ex20
1 files changed, 10 insertions, 10 deletions
diff --git a/lib/pleroma/web/rich_media/backfill.ex b/lib/pleroma/web/rich_media/backfill.ex
index 386e2023a..4ec50e132 100644
--- a/lib/pleroma/web/rich_media/backfill.ex
+++ b/lib/pleroma/web/rich_media/backfill.ex
@@ -2,16 +2,6 @@
# Copyright © 2017-2022 Pleroma Authors <https://pleroma.social/>
# SPDX-License-Identifier: AGPL-3.0-only
-defmodule Pleroma.Web.RichMedia.Backfill.Task do
- alias Pleroma.Web.RichMedia.Backfill
-
- def run(args) do
- Task.Supervisor.start_child(Pleroma.TaskSupervisor, Backfill, :run, [args],
- name: {:global, {:rich_media, args.url_hash}}
- )
- end
-end
-
defmodule Pleroma.Web.RichMedia.Backfill do
alias Pleroma.Web.RichMedia.Card
alias Pleroma.Web.RichMedia.Parser
@@ -99,3 +89,13 @@ defmodule Pleroma.Web.RichMedia.Backfill do
defp warm_cache(key, val), do: @cachex.put(:rich_media_cache, key, val)
defp negative_cache(key, ttl \\ nil), do: @cachex.put(:rich_media_cache, key, nil, ttl: ttl)
end
+
+defmodule Pleroma.Web.RichMedia.Backfill.Task do
+ alias Pleroma.Web.RichMedia.Backfill
+
+ def run(args) do
+ Task.Supervisor.start_child(Pleroma.TaskSupervisor, Backfill, :run, [args],
+ name: {:global, {:rich_media, args.url_hash}}
+ )
+ end
+end