From 827e143c9ec282c5e9c23980b4f8f6bf88f22df5 Mon Sep 17 00:00:00 2001 From: "James D. Forrester" Date: Sat, 28 Jul 2018 16:59:08 -0700 Subject: [PATCH] GlobalFunctions: Hard-deprecate wfUseMW, unused Change-Id: Ifa532f2fb7d482238e4b922f622a79b9ab6540e8 --- RELEASE-NOTES-1.32 | 1 + includes/GlobalFunctions.php | 2 ++ 2 files changed, 3 insertions(+) diff --git a/RELEASE-NOTES-1.32 b/RELEASE-NOTES-1.32 index 00ee8a334a..bbcd6c2727 100644 --- a/RELEASE-NOTES-1.32 +++ b/RELEASE-NOTES-1.32 @@ -303,6 +303,7 @@ because of Phabricator reports. do your own lookup for page/content. mNewRev / mOldRev remains public. * The $wgExternalDiffEngine value 'wikidiff2' is deprecated. To use wikidiff2 just enable the PHP extension, and it will be autodetected. +* The wfUseMW function, soft-deprecated in 1.26, is now hard deprecated. === Other changes in 1.32 === * (T198811) The following tables have had their UNIQUE indexes turned into diff --git a/includes/GlobalFunctions.php b/includes/GlobalFunctions.php index aa8aee5ea7..4a09b9c6a1 100644 --- a/includes/GlobalFunctions.php +++ b/includes/GlobalFunctions.php @@ -2529,6 +2529,8 @@ function wfUsePHP( $req_ver ) { function wfUseMW( $req_ver ) { global $wgVersion; + wfDeprecated( __FUNCTION__, '1.26' ); + if ( version_compare( $wgVersion, (string)$req_ver, '<' ) ) { throw new MWException( "MediaWiki $req_ver required--this is only $wgVersion" ); } -- 2.20.1