pass on empty scraper url (fixes philomena-dev/philomena#81)

This commit is contained in:
byte[] 2020-12-08 15:12:31 -05:00
parent c0336f0685
commit 92ade8e543

View file

@ -13,7 +13,7 @@ defmodule PhilomenaWeb.ScraperPlug do
%{^params_name => %{^params_key => %Plug.Upload{}}} ->
conn
%{"scraper_cache" => url} when not is_nil(url) ->
%{"scraper_cache" => url} when not is_nil(url) and url != "" ->
url
|> Philomena.Http.get()
|> maybe_fixup_params(url, opts, conn)