missing err handle in main publisher loop

This commit is contained in:
Eugene 2018-12-05 00:20:26 -06:00
parent 3be483cb7a
commit 036ea70421

View file

@ -46,9 +46,12 @@ func main() {
}
for event := range notifier.Go() {
pub.Publish(event, func(r rss.Event) string {
err := pub.Publish(event, func(r rss.Event) string {
return fmt.Sprintf("%s - %s", r.Title, r.Link)
})
if err != nil {
log.Printf("[WARN] failed to publish, %s", err)
}
}
}