Fix feed update failing on missing favicon
This commit is contained in:
parent
bd42073e24
commit
04ffe0036d
|
@ -25,7 +25,8 @@ defmodule Frenzy.Task.FetchFavicon do
|
|||
favicon_url =
|
||||
fetch_favicon_url_from_webpage(site_url) || URI.merge(site_url, "/favicon.ico")
|
||||
|
||||
with %Feed{favicon_url: old_url} when old_url != favicon_url <- feed,
|
||||
with true <- is_binary(favicon_url),
|
||||
%Feed{favicon_url: old_url} when old_url != favicon_url <- feed,
|
||||
{:ok, favicon_data} <- fetch_favicon_data(favicon_url) do
|
||||
changeset =
|
||||
Feed.changeset(feed, %{
|
||||
|
|
Loading…
Reference in New Issue