1 defmodule Pleroma.Web.MediaProxy.Invalidation.Http do
2 @behaviour Pleroma.Web.MediaProxy.Invalidation
4 @impl Pleroma.Web.MediaProxy.Invalidation
5 def purge(urls, opts) do
6 method = Map.get(opts, :http_method, :purge)
7 headers = Map.get(opts, :http_headers, [])
8 options = Map.get(opts, :http_options, [])
10 Enum.each(urls, fn url ->
11 Pleroma.HTTP.request(method, url, "", headers, options)