From 9a7e374e1670b04f506d4d2eecd903c253a8214a Mon Sep 17 00:00:00 2001 From: Giuseppe Bilotta Date: Fri, 18 Jul 2008 14:02:08 +0200 Subject: rss plugin: strip whitespace from link, category and author --- data/rbot/plugins/rss.rb | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'data') diff --git a/data/rbot/plugins/rss.rb b/data/rbot/plugins/rss.rb index 9d48108e..77d897ca 100644 --- a/data/rbot/plugins/rss.rb +++ b/data/rbot/plugins/rss.rb @@ -1035,10 +1035,13 @@ class RSSFeedsPlugin < Plugin desc = "(?)" end - link = item.link.href rescue item.link.chomp rescue nil + link = item.link.href rescue item.link rescue nil + link.strip! if link category = select_nonempty((item.category.content rescue nil), (item.dc_subject rescue nil)) + category.strip! if category author = select_nonempty((item.author.name.content rescue nil), (item.dc_creator rescue nil), (item.author rescue nil)) + author.strip! if author line1 = nil line2 = nil -- cgit v1.2.3