Undoing some broken changes on reading.

This commit is contained in:
Samuel Clay 2013-01-08 14:22:53 -08:00
parent 3f0f04704e
commit 0b1b3ee9b7
2 changed files with 2 additions and 2 deletions

View file

@ -351,7 +351,7 @@ class UserSubscription(models.Model):
for story_id in set(story_ids):
try:
story = MStory.get_story(story_feed_id=self.feed_id, story_guid=story_id)
story = MStory.objects.get(story_feed_id=self.feed_id, story_guid=story_id)
except MStory.DoesNotExist:
# Story has been deleted, probably by feed_fetcher.
continue

View file

@ -1401,7 +1401,7 @@ class MFeedPage(mongo.Document):
class MStory(mongo.Document):
'''A feed item'''
story_feed_id = mongo.IntField()
story_feed_id = mongo.IntField(unique_with='story_guid')
story_date = mongo.DateTimeField()
story_title = mongo.StringField(max_length=1024)
story_content = mongo.StringField()