Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Small tweak to the way aggregator handles modification dates; updated…

… entries no longer get bumped to the top (it was causing too many issues)

git-svn-id: http://code.djangoproject.com/svn/djangoproject.com@431 bcc190cf-cafb-0310-a4f2-bffc1f526a37
  • Loading branch information...
commit 5847c02f38211ea2d8984de9fee7d4023b6bcca6 1 parent affde5e
jacob authored
Showing with 3 additions and 10 deletions.
  1. +3 −10 django_website/apps/aggregator/bin/update_feeds.py
View
13 django_website/apps/aggregator/bin/update_feeds.py
@@ -38,17 +38,10 @@ def update_feeds():
date_modified = datetime.datetime.now()
try:
- feeditem = feed.get_feeditem(guid__exact=guid)
+ feed.get_feeditem(guid__exact=guid)
except feeditems.FeedItemDoesNotExist:
- feeditem = feed.add_feeditem(title=title,
- link=link,
- summary=content,
- guid=guid,
- date_modified=date_modified)
- else:
- feeditem.date_modified = date_modified
- feeditem.save()
-
+ feed.add_feeditem(title=title, link=link, summary=content, guid=guid, date_modified=date_modified)
+
if __name__ == '__main__':
parser = optparse.OptionParser()
parser.add_option('--settings')
Please sign in to comment.
Something went wrong with that request. Please try again.