From: James D. Forrester Date: Thu, 2 Nov 2017 18:48:15 +0000 (-0700) Subject: OutputPage: Hard-deprecate setSquidMaxage, renamed since 1.27 X-Git-Tag: 1.31.0-rc.0~1615 X-Git-Url: https://git.heureux-cyclage.org/?p=lhc%2Fweb%2Fwiklou.git;a=commitdiff_plain;h=88ba64343b1a5af32d76555199596dfc0431ca67 OutputPage: Hard-deprecate setSquidMaxage, renamed since 1.27 Renamed and deprecated in MediaWiki in f606fd8d since 1.27. Only six uses in Wikimedia-hosted git repositories, marked as dependencies. Also one use snuck back into MediaWiki itself, fixed in this patch. Depends-On: Ie8c13a6b1dc1b7861f6c27bbba996099375f066b Depends-On: Ic2ea90343efda6533c06ca1325bc85d9aa776078 Depends-On: Ibba2f486f0ecb684ded7efb09f9942f5e0f5fd7a Depends-On: Id27a48e10fd127e00f68e1020e8f40e30ba9a251 Depends-On: Ifd6db7910a71bb700484d6b588327424f11c00e0 Depends-On: I6523059941eb5f86274e364a8d5cc74b849655a4 Change-Id: I2cdfcd60fc7934830e3e6ec132958aa2aa1fe486 --- diff --git a/includes/MediaWiki.php b/includes/MediaWiki.php index 43de4ba375..9e3bc10467 100644 --- a/includes/MediaWiki.php +++ b/includes/MediaWiki.php @@ -367,7 +367,7 @@ class MediaWiki { } throw new HttpError( 500, $message ); } - $output->setSquidMaxage( 1200 ); + $output->setCdnMaxage( 1200 ); $output->redirect( $targetUrl, '301' ); return true; } diff --git a/includes/OutputPage.php b/includes/OutputPage.php index 500be8d902..4635f991c2 100644 --- a/includes/OutputPage.php +++ b/includes/OutputPage.php @@ -1976,6 +1976,7 @@ class OutputPage extends ContextSource { * @deprecated since 1.27 Use setCdnMaxage() instead */ public function setSquidMaxage( $maxage ) { + wfDeprecated( __METHOD__, '1.27' ); $this->setCdnMaxage( $maxage ); }