From e7961a8c39528562cd28ec57bbd8029af78bfd30 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Stefan=20K=C3=B6gl?= Date: Sun, 6 Jan 2013 15:27:10 +0000 Subject: [PATCH] fix podcast update when podcast has no tags --- mygpo/directory/tags.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/mygpo/directory/tags.py b/mygpo/directory/tags.py index 791e8456..27a243a4 100644 --- a/mygpo/directory/tags.py +++ b/mygpo/directory/tags.py @@ -88,6 +88,9 @@ class Topics(object): def update_category(podcast): all_tags = list(chain.from_iterable(s for s in podcast.tags.values())) + if not all_tags: + return + random_tag = choice(all_tags) category = category_for_tag(random_tag) -- 2.11.4.GIT