From: Brion Vibber Date: Tue, 19 Jun 2007 21:13:17 +0000 (+0000) Subject: * Avoid PHP notice errors when doing HTTP proxy purges for an empty list X-Git-Tag: 1.31.0-rc.0~52495 X-Git-Url: http://git.cyclocoop.org/%22.%24image2.%22?a=commitdiff_plain;h=045962ea87f31a45f3bf757b686c2e9dc6f36ac3;p=lhc%2Fweb%2Fwiklou.git * Avoid PHP notice errors when doing HTTP proxy purges for an empty list * As intended, *skip* the HTTP proxy purges when doing HTCP purges --- diff --git a/RELEASE-NOTES b/RELEASE-NOTES index f500a3006b..2388a62985 100644 --- a/RELEASE-NOTES +++ b/RELEASE-NOTES @@ -179,6 +179,8 @@ it from source control: http://www.mediawiki.org/wiki/Download_from_SVN * Escape the output of magic variables that return page name or part of it * (bug 10309) Initialise parser state properly in extractSections(), fixes some cases where section edits broke because tags were improperly stripped +* Avoid PHP notice errors when doing HTTP proxy purges for an empty list +* As intended, *skip* the HTTP proxy purges when doing HTCP purges == API changes since 1.10 == diff --git a/includes/SquidUpdate.php b/includes/SquidUpdate.php index 78cac6100d..65c85a2d6b 100644 --- a/includes/SquidUpdate.php +++ b/includes/SquidUpdate.php @@ -81,9 +81,14 @@ class SquidUpdate { echo implode("
\n", $urlArr) . "
\n"; return; }*/ + + if( empty( $urlArr ) ) { + return; + } - if ( $wgHTCPMulticastAddress && $wgHTCPPort ) - SquidUpdate::HTCPPurge( $urlArr ); + if ( $wgHTCPMulticastAddress && $wgHTCPPort ) { + return SquidUpdate::HTCPPurge( $urlArr ); + } $fname = 'SquidUpdate::purge'; wfProfileIn( $fname );