Skip to content

Commit

Permalink
Merge pull request #134 from xcffl/feed-item-date-fallback
Browse files Browse the repository at this point in the history
Feed item date fallback
  • Loading branch information
yang991178 committed Dec 26, 2020
2 parents b2f1a98 + f566e7f commit d5c0f48
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/scripts/models/item.ts
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ export class RSSItem {
this.title = item.title || intl.get("article.untitled")
this.link = item.link || ""
this.fetchedDate = new Date()
this.date = item.isoDate ? new Date(item.isoDate) : this.fetchedDate
this.date = new Date(item.isoDate ?? item.pubDate ?? this.fetchedDate)
this.creator = item.creator
this.hasRead = false
this.starred = false
Expand Down

0 comments on commit d5c0f48

Please sign in to comment.