Added ability to reject and rework article
This commit is contained in:
@ -8,15 +8,15 @@ import (
|
||||
"streifling.com/jason/cpolis/cmd/model"
|
||||
)
|
||||
|
||||
func GetChannel(db *model.DB, title, link, desc string) (*rss.Channel, error) {
|
||||
func GetChannel(db *model.DB, title, link, description string) (*rss.Channel, error) {
|
||||
channel := &rss.Channel{
|
||||
Title: title,
|
||||
Link: link,
|
||||
Description: desc,
|
||||
Description: description,
|
||||
Items: make([]*rss.Item, 0),
|
||||
}
|
||||
|
||||
articles, err := db.GetCertainArticles(true)
|
||||
articles, err := db.GetCertainArticles(true, false)
|
||||
if err != nil {
|
||||
return nil, fmt.Errorf("error fetching published articles: %v", err)
|
||||
}
|
||||
@ -40,7 +40,7 @@ func GetChannel(db *model.DB, title, link, desc string) (*rss.Channel, error) {
|
||||
Title: article.Title,
|
||||
Author: user.FirstName + user.LastName,
|
||||
PubDate: article.Created.Format(time.RFC1123Z),
|
||||
Description: article.Desc,
|
||||
Description: article.Description,
|
||||
Content: &rss.Content{Value: article.Content},
|
||||
Categories: tagNames,
|
||||
})
|
||||
|
Reference in New Issue
Block a user