From fbe14ed2ea652a7c2914ae7c74000b8749da535a Mon Sep 17 00:00:00 2001 From: lxnay Date: Fri, 31 Oct 2008 21:03:11 +0000 Subject: [PATCH] Entropy/DistributionUGCInterface: insert_youtube_video(): if no keywords are specified, make the keyword argument of gdata.media = None git-svn-id: http://svn.sabayonlinux.org/projects/entropy/trunk@2599 cd1c1023-2f26-0410-ae45-c471fc1f0318 --- libraries/entropy.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/libraries/entropy.py b/libraries/entropy.py index 825a67edf..958ebc9b0 100644 --- a/libraries/entropy.py +++ b/libraries/entropy.py @@ -18329,6 +18329,9 @@ class DistributionUGCInterface(RemoteDbSkelInterface): return False, None mykeywords = ', '.join([x.strip().strip(',') for x in keywords.split() if (x.strip() and x.strip(",") and (len(x.strip()) > 4))]) + gd_keywords = None + if mykeywords: gd_keywords = self.gdata.media.Keywords(text = mykeywords) + mydescription = "%s: %s" % (pkgkey,description,) mytitle = "%s: %s" % (self.system_name,title,) my_media_group = self.gdata.media.Group( @@ -18337,7 +18340,7 @@ class DistributionUGCInterface(RemoteDbSkelInterface): description_type = 'plain', text = mydescription ), - keywords = self.gdata.media.Keywords(text = mykeywords), + keywords = gd_keywords, category = self.gdata.media.Category( text = 'Tech', scheme = 'http://gdata.youtube.com/schemas/2007/categories.cat',