···1313 GUID string
1414 Title string
1515 Description string
1616+ Comments string
1617 Link string
1718 Published time.Time
1819}
···4142 }
42434344 // Limit the number of items to return
4444- maxItems := len(feed.Items)
4545- items := make([]*FeedItem, 0, maxItems)
4646- for i := 0; i < maxItems; i++ {
4747- item := feed.Items[i]
4848-4545+ items := make([]*FeedItem, 0, len(feed.Items))
4646+ for _, item := range feed.Items {
4947 published := time.Now()
5048 if item.PublishedParsed != nil {
5149 published = *item.PublishedParsed
···5957 guid = item.Link
6058 }
61596060+ // Check for comments link in custom fields
6161+ comments, _ := item.Custom["comments"]
6262+6263 items = append(items, &FeedItem{
6364 GUID: guid,
6465 Title: item.Title,
6566 Description: item.Description,
6767+ Comments: comments,
6668 Link: item.Link,
6769 Published: published,
6870 })
+5-1
main.go
···242242}
243243244244func formatPost(item *rss.FeedItem) string {
245245- // Start with title
246245 text := item.Title
247246248247 // Add link if available
249248 if item.Link != "" {
250249 text += "\n\n" + item.Link
250250+ }
251251+252252+ // Add comments if available
253253+ if item.Comments != "" {
254254+ text += "\n\nComments: " + item.Comments
251255 }
252256253257 // Truncate if too long