mirror of
https://github.com/Ranchero-Software/NetNewsWire.git
synced 2024-12-28 18:40:26 +01:00
Adjust scoring in FeedSpecifier to slightly prefer JSON feeds.
This commit is contained in:
parent
489cf8e29b
commit
23af6b4d29
@ -102,11 +102,17 @@ private extension FeedSpecifier {
|
||||
if urlString.hasSuffix("/feed") {
|
||||
score = score + 4
|
||||
}
|
||||
if urlString.rs_caseInsensitiveContains("json") {
|
||||
score = score + 6
|
||||
}
|
||||
|
||||
if let title = title {
|
||||
if title.rs_caseInsensitiveContains("comments") {
|
||||
score = score - 10
|
||||
}
|
||||
if title.rs_caseInsensitiveContains("json") {
|
||||
score = score + 1
|
||||
}
|
||||
}
|
||||
|
||||
return score
|
||||
|
Loading…
Reference in New Issue
Block a user