mirror of
https://github.com/Ranchero-Software/NetNewsWire
synced 2026-12-02 02:22:25 +00:00
Look for images in HTML when provided thumbnail fails or is too small.
This commit is contained in:
1 parent
14f570bbf1
commit
3cff328792
2 files changed
+20
No files matched your search
@@ -1281,7 +1281,18 @@ private extension MainTimelineViewController {
|
||||
}
|
||||
// Articles that used the failed URL now get their next source, or none.
|
||||
let articleIDs = Set(thumbnailURLCache.filter { $0.value == url }.keys)
|
||||
guard !articleIDs.isEmpty else {
|
||||
return
|
||||
}
|
||||
thumbnailURLsDidChange(for: articleIDs)
|
||||
|
||||
// A failed provided image falls back to images in the HTML.
|
||||
guard let articlesUsingURL = articles?.filter({ articleIDs.contains($0.articleID) }) else {
|
||||
return
|
||||
}
|
||||
Task {
|
||||
await ArticleThumbnailFinder.shared.discoverThumbnailURLs(for: articlesUsingURL)
|
||||
}
|
||||
}
|
||||
|
||||
@objc func contentSizeCategoryDidChange(_ note: Notification) {
|
||||
|
||||
Reference in new issue
Block a user