mirror of
https://akkoma.dev/AkkomaGang/akkoma.git
synced 2024-11-27 00:09:35 +00:00
[#2497] Fixed merge issue.
This commit is contained in:
parent
61180ab6f4
commit
9faa632037
|
@ -12,8 +12,8 @@ defmodule Pleroma.Web.MediaProxy.MediaProxyController do
|
||||||
|
|
||||||
def remote(conn, %{"sig" => sig64, "url" => url64}) do
|
def remote(conn, %{"sig" => sig64, "url" => url64}) do
|
||||||
with {_, true} <- {:enabled, MediaProxy.enabled?()},
|
with {_, true} <- {:enabled, MediaProxy.enabled?()},
|
||||||
{_, false} <- {:in_banned_urls, MediaProxy.in_banned_urls(url)},
|
|
||||||
{:ok, url} <- MediaProxy.decode_url(sig64, url64),
|
{:ok, url} <- MediaProxy.decode_url(sig64, url64),
|
||||||
|
{_, false} <- {:in_banned_urls, MediaProxy.in_banned_urls(url)},
|
||||||
:ok <- MediaProxy.verify_request_path_and_url(conn, url) do
|
:ok <- MediaProxy.verify_request_path_and_url(conn, url) do
|
||||||
proxy_opts = Config.get([:media_proxy, :proxy_opts], [])
|
proxy_opts = Config.get([:media_proxy, :proxy_opts], [])
|
||||||
ReverseProxy.call(conn, url, proxy_opts)
|
ReverseProxy.call(conn, url, proxy_opts)
|
||||||
|
|
Loading…
Reference in a new issue