Making Source field optional

This commit is contained in:
Milan Aleksic
2017-05-31 18:12:31 +02:00
committed by Kamil Kisiel
parent b238132b07
commit d7974c3e26
+3 -1
View File
@@ -90,11 +90,13 @@ func newRssItem(i *Item) *RssItem {
item := &RssItem{
Title: i.Title,
Link: i.Link.Href,
Source: i.Source.Href,
Description: i.Description,
Guid: i.Id,
PubDate: anyTimeFormat(time.RFC1123Z, i.Created, i.Updated),
}
if i.Source != nil {
item.Source = i.Source.Href
}
intLength, err := strconv.ParseInt(i.Link.Length, 10, 64)