diff options
author | Tom Willemsen | 2012-03-10 14:03:28 +0100 |
---|---|---|
committer | Tom Willemsen | 2012-03-10 14:03:28 +0100 |
commit | eddb9cbef7fa9aba198d6e11ea018b09f3e877af (patch) | |
tree | 062c8273d44d145b7c7e43496968cd202eb011ca /aggregator | |
parent | 63d1ed7d192e2e17665add4f70dca10c2681d704 (diff) | |
download | ryuslash.org-eddb9cbef7fa9aba198d6e11ea018b09f3e877af.tar.gz ryuslash.org-eddb9cbef7fa9aba198d6e11ea018b09f3e877af.zip |
Always make sure a feed's updated value is correct
Diffstat (limited to 'aggregator')
-rw-r--r-- | aggregator/management/commands/load_feeds.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/aggregator/management/commands/load_feeds.py b/aggregator/management/commands/load_feeds.py index c143052..3f698e4 100644 --- a/aggregator/management/commands/load_feeds.py +++ b/aggregator/management/commands/load_feeds.py @@ -32,6 +32,8 @@ class Command(BaseCommand): updated=updated, feed=feed) post.save() - feed.updated = datetime.datetime.now() + last_updated = Post.objects.filter(feed=feed)\ + .order_by('-updated')[0].updated + feed.updated = last_updated feed.save() |