Fix incorrect function call scope in Title.php
authorwithoutaname <drevitchi@gmail.com>
Wed, 16 Jul 2014 22:17:47 +0000 (15:17 -0700)
committerwithoutaname <drevitchi@gmail.com>
Wed, 16 Jul 2014 22:17:47 +0000 (15:17 -0700)
Calls to getTitleParser() and getTitleFormatter() were using $this->
but the functions were declared static.

Change-Id: If21be84c68725b2afe181229cb697b948d26d6c6

includes/Title.php

index 477373a..746ffab 100644 (file)
@@ -977,7 +977,7 @@ class Title {
                }
 
                try {
-                       $formatter = $this->getTitleFormatter();
+                       $formatter = self::getTitleFormatter();
                        return $formatter->getNamespaceName( $this->mNamespace, $this->mDbkeyform );
                } catch ( InvalidArgumentException $ex )  {
                        wfDebug( __METHOD__ . ': ' . $ex->getMessage() . "\n" );
@@ -3291,7 +3291,7 @@ class Title {
                        // @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.
-                       $parser = $this->getTitleParser();
+                       $parser = self::getTitleParser();
                        $parts = $parser->splitTitleString( $dbkey, $this->getDefaultNamespace() );
                } catch ( MalformedTitleException $ex ) {
                        return false;