Compare commits

..

1 Commits

Author SHA1 Message Date
Shadowfacts c90f2d48e2
Add filter web UI 2019-03-10 21:39:31 -04:00
1 changed files with 2 additions and 1 deletions

View File

@ -81,6 +81,7 @@ defmodule Frenzy.UpdateFeeds do
feed = Repo.preload(feed, :items) feed = Repo.preload(feed, :items)
Enum.map(rss.items, fn entry -> Enum.map(rss.items, fn entry ->
# todo: use Repo.exists for this
if !Enum.any?(feed.items, fn item -> item.guid == entry.id end) do if !Enum.any?(feed.items, fn item -> item.guid == entry.id end) do
create_item(feed, entry) create_item(feed, entry)
end end
@ -100,7 +101,7 @@ defmodule Frenzy.UpdateFeeds do
{:err, reason} -> {:err, reason} ->
Logger.warn("Unable to fetch article for #{url}: #{reason}") Logger.warn("Unable to fetch article for #{url}: #{reason}")
entry.content || entry.summary entry.description
end end
changeset = changeset =