Add thumbnailURL.

This commit is contained in:
Brent Simmons committed 2026-10-23 12:09:43 -07:00
1 parent 1a07f175d2
commit 405c82260b
4 files changed
+6 -2

No files matched your search

@@ -166,7 +166,7 @@ private extension JSONFeedParser {
}
let attachments = parseAttachments(itemDictionary)
return ParsedItem(syncServiceID: nil, uniqueID: uniqueID, feedURL: feedURL, url: url, externalURL: externalURL, title: title, language: language, contentHTML: contentHTML, contentText: contentText, markdown: nil, summary: summary, imageURL: imageURL, bannerImageURL: bannerImageURL, datePublished: datePublished, dateModified: dateModified, authors: authors, tags: tags, attachments: attachments)
return ParsedItem(syncServiceID: nil, uniqueID: uniqueID, feedURL: feedURL, url: url, externalURL: externalURL, title: title, language: language, contentHTML: contentHTML, contentText: contentText, markdown: nil, summary: summary, imageURL: imageURL, thumbnailURL: nil, bannerImageURL: bannerImageURL, datePublished: datePublished, dateModified: dateModified, authors: authors, tags: tags, attachments: attachments)
}
static func parseTitle(_ itemDictionary: JSONDictionary, _ feedURL: String) -> String? {
@@ -130,7 +130,7 @@ private extension RSSInJSONParser {
}
if let uniqueID = uniqueID {
return ParsedItem(syncServiceID: nil, uniqueID: uniqueID, feedURL: feedURL, url: nil, externalURL: externalURL, title: title, language: nil, contentHTML: contentHTML, contentText: contentText, markdown: nil, summary: nil, imageURL: nil, bannerImageURL: nil, datePublished: datePublished, dateModified: nil, authors: authors, tags: tags, attachments: attachments)
return ParsedItem(syncServiceID: nil, uniqueID: uniqueID, feedURL: feedURL, url: nil, externalURL: externalURL, title: title, language: nil, contentHTML: contentHTML, contentText: contentText, markdown: nil, summary: nil, imageURL: nil, thumbnailURL: nil, bannerImageURL: nil, datePublished: datePublished, dateModified: nil, authors: authors, tags: tags, attachments: attachments)
}
return nil
}
@@ -22,6 +22,7 @@ public struct ParsedItem: Hashable, Sendable {
public let markdown: String?
public let summary: String?
public let imageURL: String?
public let thumbnailURL: String?
public let bannerImageURL: String?
public let datePublished: Date?
public let dateModified: Date?
@@ -41,6 +42,7 @@ public struct ParsedItem: Hashable, Sendable {
markdown: String?,
summary: String?,
imageURL: String?,
thumbnailURL: String?,
bannerImageURL: String?,
datePublished: Date?,
dateModified: Date?,
@@ -58,6 +60,7 @@ public struct ParsedItem: Hashable, Sendable {
self.markdown = markdown
self.summary = summary
self.imageURL = imageURL
self.thumbnailURL = thumbnailURL
self.bannerImageURL = bannerImageURL
self.datePublished = datePublished
self.dateModified = dateModified
@@ -100,6 +100,7 @@ final class RSSItem {
markdown: markdown,
summary: itemSummary,
imageURL: imageURL ?? itunesImageURL,
thumbnailURL: nil,
bannerImageURL: nil,
datePublished: datePublished,
dateModified: dateModified,