Don’t show author name if it’s the same as the feed name. Issue #290
This commit is contained in:
parent
48b859fbd2
commit
1b477a4e31
|
@ -400,6 +400,15 @@ class ArticleRenderer {
|
|||
return ""
|
||||
}
|
||||
|
||||
// If the author's name is the same as the feed, then we don't want to display it.
|
||||
// This code assumes that multiple authors would never match the feed name so that
|
||||
// if there feed owner has an article co-author all authors are given the byline.
|
||||
if authors.count == 1, let author = authors.first {
|
||||
if author.name == article.feed?.nameForDisplay {
|
||||
return ""
|
||||
}
|
||||
}
|
||||
|
||||
var byline = ""
|
||||
var isFirstAuthor = true
|
||||
|
||||
|
@ -430,8 +439,8 @@ class ArticleRenderer {
|
|||
}
|
||||
}
|
||||
|
||||
|
||||
return byline
|
||||
|
||||
}
|
||||
|
||||
private func renderedHTML() -> String {
|
||||
|
|
Loading…
Reference in New Issue