From c41c0761b699d4e4b4f1b78ca3752982cbb9f038 Mon Sep 17 00:00:00 2001 From: pictuga Date: Mon, 6 Apr 2015 22:15:59 +0800 Subject: [PATCH] feedify: don't insert useless url when none is found --- morss/feedify.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/morss/feedify.py b/morss/feedify.py index c90b0b0..b21c24e 100644 --- a/morss/feedify.py +++ b/morss/feedify.py @@ -191,8 +191,9 @@ class Builder(object): feed_item['title'] = self.string(item, 'item_title') if 'item_link' in self.rule: url = self.string(item, 'item_link') - url = urljoin(self.link, url) - feed_item['link'] = url + if url: + url = urljoin(self.link, url) + feed_item['link'] = url if 'item_desc' in self.rule: feed_item['desc'] = self.string(item, 'item_desc') if 'item_content' in self.rule: