From f56539581969b01c4d26696afae8c29f2fcfb12e Mon Sep 17 00:00:00 2001 From: danilo silva Date: Sun, 7 Jun 2020 21:19:18 +0000 Subject: [PATCH] supporting also `item image` as format for cover --- lib/podcast_feed/provider/archive/parser.ex | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/podcast_feed/provider/archive/parser.ex b/lib/podcast_feed/provider/archive/parser.ex index 9019949..8105472 100644 --- a/lib/podcast_feed/provider/archive/parser.ex +++ b/lib/podcast_feed/provider/archive/parser.ex @@ -103,7 +103,7 @@ defmodule PodcastFeed.Provider.Archive.Parser do defp fetch_cover(%{identifier: identifier, archive_metadata: %{"files" => files}}) do filename = files |> Enum.filter(fn f -> f["source"] == "original" end) - |> Enum.filter(fn f -> f["format"] =~ ~r/JPG|JPEG|PNG|GIF/i end) + |> Enum.filter(fn f -> f["format"] =~ ~r/JPG|JPEG|PNG|GIF|Item Image/i end) |> List.first() |> case do nil -> nil