From 09d2e4ae72564cca843293181bb3c9f5bfe0cafe Mon Sep 17 00:00:00 2001 From: Shadowfacts Date: Fri, 29 May 2020 20:06:42 -0400 Subject: [PATCH] Fix wrong return type --- lib/frenzy/task/fetch_favicon.ex | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/frenzy/task/fetch_favicon.ex b/lib/frenzy/task/fetch_favicon.ex index e3278ad..305c858 100644 --- a/lib/frenzy/task/fetch_favicon.ex +++ b/lib/frenzy/task/fetch_favicon.ex @@ -59,7 +59,7 @@ defmodule Frenzy.Task.FetchFavicon do case Floki.find(html_tree, "link[rel=icon]") do [] -> - {:error, "No element matching link[rel=icon]"} + nil links -> links @@ -83,7 +83,7 @@ defmodule Frenzy.Task.FetchFavicon do end) |> case do nil -> - {:error, "No link[rel=icon] with type of image/png"} + nil link -> link