Deprecate Parser::fetchFile() since it's unused
authorKunal Mehta <legoktm@member.fsf.org>
Mon, 28 May 2018 06:16:28 +0000 (23:16 -0700)
committerKunal Mehta <legoktm@member.fsf.org>
Mon, 28 May 2018 06:17:50 +0000 (23:17 -0700)
Change-Id: Ic2bc3dd0479a373159a22da5f0a6961e212352ff

RELEASE-NOTES-1.32
includes/parser/Parser.php

index c1b579a..c54227a 100644 (file)
@@ -144,6 +144,7 @@ because of Phabricator reports.
   with the 'unwatch' action parameter instead.
 * IcuCollation::getICUVersion() is deprecated, as you can just use the PHP
   constant INTL_ICU_VERSION directly in all versions that MediaWiki supports.
+* Parser::fetchFile() is deprecated. Use ::fetchFileAndTitle() instead.
 
 === Other changes in 1.32 ===
 * Soft hyphens (U+00AD) are now automatically removed from titles; these
index 2696f4d..dfd9602 100644 (file)
@@ -3689,8 +3689,10 @@ class Parser {
         * @param Title $title
         * @param array $options Array of options to RepoGroup::findFile
         * @return File|bool
+        * @deprecated since 1.32, use fetchFileAndTitle instead
         */
        public function fetchFile( $title, $options = [] ) {
+               wfDeprecated( __METHOD__, '1.32' );
                return $this->fetchFileAndTitle( $title, $options )[0];
        }