Auto-deny feeds that are not RSS or Atom type
Feeds with type other than 'rss' or 'atom' (e.g., 'unknown') are now automatically denied on discovery. Also updated 164 existing feeds. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
@@ -178,11 +178,13 @@ type Feed struct {
|
||||
// saveFeed stores a feed in PostgreSQL
|
||||
func (c *Crawler) saveFeed(feed *Feed) error {
|
||||
// Default publishStatus to "held" if not set
|
||||
// Auto-deny feeds with no language specified
|
||||
// Auto-deny feeds with no language or non-RSS/Atom type
|
||||
publishStatus := feed.PublishStatus
|
||||
if publishStatus == "" {
|
||||
if feed.Language == "" {
|
||||
publishStatus = "deny"
|
||||
} else if feed.Type != "rss" && feed.Type != "atom" {
|
||||
publishStatus = "deny"
|
||||
} else {
|
||||
publishStatus = "held"
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user