Changeset - 252f29af8119
[Not reviewed]
0 1 0
Bradley Kuhn (bkuhn) - 10 years ago 2014-07-14 15:56:30
bkuhn@ebb.org
Make sure return values match title.

I received this error from the feeds:

AttributeError at /feeds/news/

'PressRelease' object has no attribute 'title'

Request Method: GET
Request URL: http://sfconservancy.org/feeds/news/
Django Version: 1.4.5
Exception Type: AttributeError

'PressRelease' object has no attribute 'title'
Exception Location: /var/www/conservancy/feeds.py in item_title, line 46

I think this change fixes that.
1 file changed with 6 insertions and 6 deletions:
0 comments (0 inline, 0 general)
www/conservancy/feeds.py
Show inline comments
...
 
@@ -45,6 +45,6 @@ class PressReleaseFeed(Feed):
 
    def item_title(self, item):
 
        return item.title
 
        return item.headline
 

	
 
    def item_description(self, item):
 
        return item.title
 
        return item.summary
 

	
...
 
@@ -84,6 +84,6 @@ class OmnibusFeed(ConservancyFeedBase):
 
    def item_title(self, item):
 
        return item.title
 
        return item.headline
 

	
 
    def item_description(self, item):
 
        return item.description
 
        return item.summary
 

	
...
 
@@ -213,6 +213,6 @@ class BlogFeed(ConservancyFeedBase):
 
    def item_title(self, item):
 
        return item.title
 
        return item.headline
 

	
 
    def item_description(self, item):
 
        return item.description
 
        return item.summary
 

	
0 comments (0 inline, 0 general)