Ticket #5855: patch-5855-2.diff
File patch-5855-2.diff, 1.0 KB (added by , 17 years ago) |
---|
-
django/contrib/syndication/feeds.py
55 55 return attr() 56 56 return attr 57 57 58 def get_object(self, bits): 59 return None 60 58 61 def get_feed(self, url=None): 59 62 """ 60 63 Returns a feedgenerator.DefaultFeed object, fully populated, for 61 64 this feed. Raises FeedDoesNotExist for invalid parameters. 62 65 """ 63 66 if url: 64 try: 65 obj = self.get_object(url.split('/')) 66 except (AttributeError, ObjectDoesNotExist): 67 raise FeedDoesNotExist 67 bits = url.split('/') 68 68 else: 69 obj = None69 bits = [] 70 70 71 try: 72 obj = self.get_object(bits) 73 except ObjectDoesNotExist: 74 raise FeedDoesNotExist 75 71 76 if Site._meta.installed: 72 77 current_site = Site.objects.get_current() 73 78 else: