jenkins-bot has submitted this change and it was merged.

Change subject: phpdoc @return MediaWikiTitleCodec in Title::getTitleParser
......................................................................


phpdoc @return MediaWikiTitleCodec in Title::getTitleParser

This will always return a MediaWikiTitleCodec object.
This is called in Title::secureAndSplit which expects
the method splitTitleString which is only in this
implementation and not the interface

Change-Id: Ibb6cdcf7deb6c1080e320379aa58981e9935ca33
---
M includes/Title.php
1 file changed, 5 insertions(+), 5 deletions(-)

Approvals:
  Daniel Kinzler: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/includes/Title.php b/includes/Title.php
index 55c7179..50721af 100644
--- a/includes/Title.php
+++ b/includes/Title.php
@@ -161,9 +161,9 @@
         * Avoid usage of this singleton by using TitleValue
         * and the associated services when possible.
         *
-        * @return TitleParser
+        * @return MediaWikiTitleCodec
         */
-       private static function getTitleParser() {
+       private static function getMediaWikiTitleCodec() {
                global $wgContLang, $wgLocalInterwikis;
 
                static $titleCodec = null;
@@ -200,9 +200,9 @@
         * @return TitleFormatter
         */
        private static function getTitleFormatter() {
-               // NOTE: we know that getTitleParser() returns a 
MediaWikiTitleCodec,
+               // NOTE: we know that getMediaWikiTitleCodec() returns a 
MediaWikiTitleCodec,
                //      which implements TitleFormatter.
-               return self::getTitleParser();
+               return self::getMediaWikiTitleCodec();
        }
 
        function __construct() {
@@ -3353,7 +3353,7 @@
                // @note: splitTitleString() is a temporary hack to allow 
MediaWikiTitleCodec to share
                //        the parsing code with Title, while avoiding massive 
refactoring.
                // @todo: get rid of secureAndSplit, refactor parsing code.
-               $titleParser = self::getTitleParser();
+               $titleParser = self::getMediaWikiTitleCodec();
                // MalformedTitleException can be thrown here
                $parts = $titleParser->splitTitleString( $dbkey, 
$this->getDefaultNamespace() );
 

-- 
To view, visit https://gerrit.wikimedia.org/r/268145
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ibb6cdcf7deb6c1080e320379aa58981e9935ca33
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: Addshore <[email protected]>
Gerrit-Reviewer: Aude <[email protected]>
Gerrit-Reviewer: Daniel Kinzler <[email protected]>
Gerrit-Reviewer: Legoktm <[email protected]>
Gerrit-Reviewer: jenkins-bot <>

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to