From 9ac5888b3fd141b11e21b7c2cc96b47ba9ad1458 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Stefan=20K=C3=B6gl?= Date: Wed, 26 Jan 2011 13:26:50 +0200 Subject: [PATCH] fix bug with inlining logo --- feedservice/feeddownloader.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/feedservice/feeddownloader.py b/feedservice/feeddownloader.py index a61b31e..15b184a 100644 --- a/feedservice/feeddownloader.py +++ b/feedservice/feeddownloader.py @@ -68,7 +68,7 @@ def parse_feed(feed_url, inline_logo, scale_to, strip_html, modified): ('urls', False, lambda: get_redirects(feed_url)), ('new_location', False, lambda: get_newlocation(feed)), ('logo', False, lambda: get_podcast_logo(feed)), - ('logo_data', False, lambda: get_data_uri(inline_logo, podcast['logo'], scale_to, modified)), + ('logo_data', False, lambda: get_data_uri(inline_logo, podcast.get('logo', None), scale_to, modified)), ('tags', False, lambda: get_feed_tags(feed.feed)), ('episodes', False, lambda: get_episodes(feed, strip_html)), ('content_types', False, lambda: get_podcast_types(podcast)), @@ -116,7 +116,7 @@ def get_data_uri(inline_logo, url, size=None, modified_since=None): import base64 from google.appengine.api import images - if not inline_logo: + if not inline_logo or not url: return None url, content, last_modified = urlstore.get_url(url) -- 2.11.4.GIT