Set feed.title from the OPML — don’t just leave it blank.

This commit is contained in:
Brent Simmons 2019-02-02 18:08:01 -08:00
parent 30324c8ec0
commit 448293a836
1 changed files with 7 additions and 2 deletions

View File

@ -744,8 +744,13 @@ private extension Account {
func createFeed(with opmlFeedSpecifier: RSOPMLFeedSpecifier) -> Feed { func createFeed(with opmlFeedSpecifier: RSOPMLFeedSpecifier) -> Feed {
let feed = Feed(account: self, url: opmlFeedSpecifier.feedURL, feedID: opmlFeedSpecifier.feedURL) let feed = Feed(account: self, url: opmlFeedSpecifier.feedURL, feedID: opmlFeedSpecifier.feedURL)
if let feedTitle = opmlFeedSpecifier.title, feed.editedName == nil { if let feedTitle = opmlFeedSpecifier.title {
feed.editedName = feedTitle if feed.name == nil {
feed.name = feedTitle
}
if feed.editedName == nil {
feed.editedName = feedTitle
}
} }
return feed return feed
} }