r47484 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r47483‎ | r47484 | r47485 >
Date:11:20, 19 February 2009
Author:ialex
Status:ok
Tags:
Comment:
No need to get a DB object since we don't use it there
Modified paths:
  • /trunk/phase3/includes/Title.php (modified) (history)

Diff [purge]

Index: trunk/phase3/includes/Title.php
@@ -1613,7 +1613,6 @@
16141614 return $this->mHasSubpages;
16151615 }
16161616
1617 - $db = wfGetDB( DB_SLAVE );
16181617 $subpages = $this->getSubpages( 1 );
16191618 if( $subpages instanceof TitleArray )
16201619 return $this->mHasSubpages = (bool)$subpages->count();
@@ -1626,7 +1625,7 @@
16271626 * @return mixed TitleArray, or empty array if this page's namespace
16281627 * doesn't allow subpages
16291628 */
1630 - public function getSubpages($limit = -1) {
 1629+ public function getSubpages( $limit = -1 ) {
16311630 if( !MWNamespace::hasSubpages( $this->getNamespace() ) )
16321631 return array();
16331632

Status & tagging log