Clean some unused config key
Signed-off-by: Thomas Citharel <tcit@tcit.fr>
This commit is contained in:
parent
6a063cf655
commit
882661e22c
|
@ -92,8 +92,7 @@ config :mobilizon, :media_proxy,
|
||||||
follow_redirect: true,
|
follow_redirect: true,
|
||||||
pool: :media
|
pool: :media
|
||||||
]
|
]
|
||||||
],
|
]
|
||||||
whitelist: []
|
|
||||||
|
|
||||||
config :mobilizon, Mobilizon.Web.Email.Mailer,
|
config :mobilizon, Mobilizon.Web.Email.Mailer,
|
||||||
adapter: Bamboo.SMTPAdapter,
|
adapter: Bamboo.SMTPAdapter,
|
||||||
|
|
|
@ -29,10 +29,6 @@ defmodule Mobilizon.Web.MediaProxy do
|
||||||
|
|
||||||
def enabled?, do: Config.get([:media_proxy, :enabled], false)
|
def enabled?, do: Config.get([:media_proxy, :enabled], false)
|
||||||
|
|
||||||
# Note: media proxy must be enabled for media preview proxy in order to load all
|
|
||||||
# non-local non-whitelisted URLs through it and be sure that body size constraint is preserved.
|
|
||||||
def preview_enabled?, do: enabled?() and !!Config.get([:media_preview_proxy, :enabled])
|
|
||||||
|
|
||||||
def local?(url), do: String.starts_with?(url, Web.Endpoint.url())
|
def local?(url), do: String.starts_with?(url, Web.Endpoint.url())
|
||||||
|
|
||||||
defp base64_sig64(url) do
|
defp base64_sig64(url) do
|
||||||
|
|
Loading…
Reference in a new issue