cool - rss now works :-)
This commit is contained in:
parent
21467128a6
commit
3f59652d05
2 changed files with 4 additions and 4 deletions
|
@ -15,8 +15,8 @@
|
|||
[]
|
||||
(rss.))
|
||||
|
||||
(defn parse-feed [payload]
|
||||
(for [{:keys [title isoDate pubDate content link]} (:items payload)]
|
||||
(defn parse-feed [item]
|
||||
(let [{:keys [title isoDate pubDate content link]} item]
|
||||
{:created-at (js/Date. (or isoDate pubDate))
|
||||
:text (str title
|
||||
"\n\n"
|
||||
|
|
|
@ -172,13 +172,13 @@
|
|||
(let [{:keys [source target resolve-urls?]} transformation]
|
||||
(fn [payload]
|
||||
(->> (infra/js->edn payload)
|
||||
(:items)
|
||||
(map rss/parse-feed)
|
||||
(debug)
|
||||
(filter #(> (:created-at %) last-post-time))
|
||||
(remove #(blocked-content? transformation (:text %)))
|
||||
(map #(intermediate-resolve-urls resolve-urls? %))
|
||||
(map #(twitter/nitter-url source %))
|
||||
(map #(perform-replacements transformation %))
|
||||
(debug)
|
||||
(map #(intermediate-to-mastodon mastodon-auth target %))
|
||||
(masto/post-items mastodon-auth target last-post-time)))))
|
||||
|
||||
|
|
Reference in a new issue