diff --git a/Shared/Article Extractor/ArticleExtractorConfig.swift b/Shared/Article Extractor/ArticleExtractorConfig.swift index 7f4518fd4..b2ca59cbc 100644 --- a/Shared/Article Extractor/ArticleExtractorConfig.swift +++ b/Shared/Article Extractor/ArticleExtractorConfig.swift @@ -9,7 +9,7 @@ import Foundation enum ArticleExtractorConfig { - static let clientId = "{MERCURYID}" - static let clientSecret = "{MERCURYSECRET}" + static let clientId = "netnewswire" + static let clientSecret = "PM9QZZwckFPLcJdUt4BADDqwHdKCAy8zxaAakjmpGdbjEjfcAdU3CTNdBf8Lw" static let clientURL = "https://extract.feedbin.com/parser" } diff --git a/Shared/Images/RSHTMLMetadata+Extension.swift b/Shared/Images/RSHTMLMetadata+Extension.swift index a9b57438e..cf5dd8ba7 100644 --- a/Shared/Images/RSHTMLMetadata+Extension.swift +++ b/Shared/Images/RSHTMLMetadata+Extension.swift @@ -20,6 +20,9 @@ extension RSHTMLMetadata { var bestImage: RSHTMLOpenGraphImage? = nil for image in openGraphImages { + if image.width / image.height > 2 { + continue + } if bestImage == nil { bestImage = image continue @@ -51,6 +54,9 @@ extension RSHTMLMetadata { var bestImage: RSHTMLMetadataAppleTouchIcon? = nil for image in icons { + if image.size.width / image.size.height > 2 { + continue + } if bestImage == nil { bestImage = image continue diff --git a/iOS/AppDelegate.swift b/iOS/AppDelegate.swift index f75dc0880..839ccf3de 100644 --- a/iOS/AppDelegate.swift +++ b/iOS/AppDelegate.swift @@ -182,7 +182,7 @@ private extension AppDelegate { let homePageURLsWithNoFaviconURL = tempDir.appendingPathComponent("HomePageURLsWithNoFaviconURLCache.plist") // If the image disk cache hasn't been flushed for 3 days and the network is available, delete it - if let flushDate = AppDefaults.lastImageCacheFlushDate, flushDate.addingTimeInterval(3600*24*3) < Date() { +// if let flushDate = AppDefaults.lastImageCacheFlushDate, flushDate.addingTimeInterval(3600*24*3) < Date() { if let reachability = try? Reachability(hostname: "apple.com") { if reachability.connection != .unavailable { for tempItem in [faviconsFolderURL, imagesFolderURL, homePageToIconURL, homePagesWithNoIconURL, homePageToFaviconURL, homePageURLsWithNoFaviconURL] { @@ -196,7 +196,7 @@ private extension AppDelegate { AppDefaults.lastImageCacheFlushDate = Date() } } - } +// } try! FileManager.default.createDirectory(at: faviconsFolderURL, withIntermediateDirectories: true, attributes: nil) let faviconsFolder = faviconsFolderURL.absoluteString