From aad2d5ef0d6423613916477b576db9025adc1b27 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Antoine=20Beaupr=C3=A9?= Date: Fri, 14 Mar 2008 04:11:07 +0000 Subject: [PATCH] silence various warnings with rss feed functionality i did not add configuration directives as requested, as it would annoy people that don't *want* to install the rss functionality. Closes: #1099 --- bureau/admin/main.php | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/bureau/admin/main.php b/bureau/admin/main.php index e631e0cb..69351b04 100644 --- a/bureau/admin/main.php +++ b/bureau/admin/main.php @@ -50,8 +50,10 @@ $mem->resetlast(); # this should work, since the debian package installs it in # /usr/share/php, which is in the include path -if (include_once('magpierss/rss_fetch.inc')) { - $rss = fetch_rss( variable_get('rss_feed') ); +$rss_url = variable_get('rss_feed'); +$inc = @include_once('magpierss/rss_fetch.inc'); +if ($inc && $rss_url) { + $rss = fetch_rss($rss_url); if ($rss) { echo "

" . _("Latest news") . "

";