Author: dom Date: 2008-10-25 00:11:24 +0100 (Sat, 25 Oct 2008) New Revision: 1247
Modified: trunk/Changes trunk/lib/OpenGuides/Utils.pm Log: Warn about errors fetching remote RSS feeds, but carry on generating the page content (fixes #228)
Modified: trunk/Changes =================================================================== --- trunk/Changes 2008-10-24 22:05:54 UTC (rev 1246) +++ trunk/Changes 2008-10-24 23:11:24 UTC (rev 1247) @@ -20,6 +20,8 @@ without explicit moderation (#203) Don't add delete links unless the user requests (#159) Fix clean target to remove everything it should (#242) + Warn about errors fetching remote RSS feeds, but carry on + generating the page content (#228)
0.63 16 August 2008 Major overhaul of RDF output.
Modified: trunk/lib/OpenGuides/Utils.pm =================================================================== --- trunk/lib/OpenGuides/Utils.pm 2008-10-24 22:05:54 UTC (rev 1246) +++ trunk/lib/OpenGuides/Utils.pm 2008-10-24 23:11:24 UTC (rev 1247) @@ -211,7 +211,13 @@ $url = $1; }
- my $rss = Wiki::Toolkit::Plugin::RSS::Reader->new(url => $url); + # We can't do much about remote errors fetching + # at this stage + my $rss = eval { Wiki::Toolkit::Plugin::RSS::Reader->new(url => $url); }; + if ( $@ ) { + warn $@; + return ''; + } my @items = $rss->retrieve;
# Ten items only at this till.
openguides-commits@lists.openguides.org