From: Sam Reed Date: Mon, 18 Apr 2011 19:00:48 +0000 (+0000) Subject: Revert r86236 X-Git-Tag: 1.31.0-rc.0~30728 X-Git-Url: http://git.cyclocoop.org/%24self?a=commitdiff_plain;h=517b6b6b5911487ca7dfd31be31421d84912a4ad;p=lhc%2Fweb%2Fwiklou.git Revert r86236 --- diff --git a/includes/QueryPage.php b/includes/QueryPage.php index 055d923160..17a641bcf0 100644 --- a/includes/QueryPage.php +++ b/includes/QueryPage.php @@ -277,7 +277,7 @@ abstract class QueryPage extends SpecialPage { $fname = get_class( $this ) . '::recache'; $dbw = wfGetDB( DB_MASTER ); - $dbr = wfGetDB( DB_SLAVE, array( $this->name(), __METHOD__, 'vslow' ) ); + $dbr = wfGetDB( DB_SLAVE, array( $this->getName(), __METHOD__, 'vslow' ) ); if ( !$dbw || !$dbr ) { return false; } @@ -288,7 +288,7 @@ abstract class QueryPage extends SpecialPage { } # Clear out any old cached data - $dbw->delete( 'querycache', array( 'qc_type' => $this->name() ), $fname ); + $dbw->delete( 'querycache', array( 'qc_type' => $this->getName() ), $fname ); # Do query $res = $this->reallyDoQuery( $limit, false ); $num = false; @@ -308,7 +308,7 @@ abstract class QueryPage extends SpecialPage { $value = 0; } - $vals[] = array( 'qc_type' => $this->name(), + $vals[] = array( 'qc_type' => $this->getName(), 'qc_namespace' => $row->namespace, 'qc_title' => $row->title, 'qc_value' => $value ); @@ -327,8 +327,8 @@ abstract class QueryPage extends SpecialPage { } # Update the querycache_info record for the page - $dbw->delete( 'querycache_info', array( 'qci_type' => $this->name() ), $fname ); - $dbw->insert( 'querycache_info', array( 'qci_type' => $this->name(), 'qci_timestamp' => $dbw->timestamp() ), $fname ); + $dbw->delete( 'querycache_info', array( 'qci_type' => $this->getName() ), $fname ); + $dbw->insert( 'querycache_info', array( 'qci_type' => $this->getName(), 'qci_timestamp' => $dbw->timestamp() ), $fname ); } return $num; @@ -416,7 +416,7 @@ abstract class QueryPage extends SpecialPage { 'qc_namespace AS namespace', 'qc_title AS title', 'qc_value AS value' ), - array( 'qc_type' => $this->name() ), + array( 'qc_type' => $this->getName() ), __METHOD__, $options ); return $dbr->resultObject( $res ); @@ -427,7 +427,7 @@ abstract class QueryPage extends SpecialPage { $dbr = wfGetDB( DB_SLAVE ); $fname = get_class( $this ) . '::getCachedTimestamp'; $this->cachedTimestamp = $dbr->selectField( 'querycache_info', 'qci_timestamp', - array( 'qci_type' => $this->name() ), $fname ); + array( 'qci_type' => $this->getName() ), $fname ); } return $this->cachedTimestamp; } @@ -483,7 +483,7 @@ abstract class QueryPage extends SpecialPage { # If updates on this page have been disabled, let the user know # that the data set won't be refreshed for now global $wgDisableQueryPageUpdate; - if ( is_array( $wgDisableQueryPageUpdate ) && in_array( $this->name(), $wgDisableQueryPageUpdate ) ) { + if ( is_array( $wgDisableQueryPageUpdate ) && in_array( $this->getName(), $wgDisableQueryPageUpdate ) ) { $wgOut->addWikiMsg( 'querypage-no-updates' ); } diff --git a/maintenance/updateSpecialPages.php b/maintenance/updateSpecialPages.php index fe56a89e7d..46d0fcc5a6 100644 --- a/maintenance/updateSpecialPages.php +++ b/maintenance/updateSpecialPages.php @@ -93,7 +93,7 @@ class UpdateSpecialPages extends Maintenance { $queryPage = new $class; } - if ( !$this->hasOption( 'only' ) || $this->getOption( 'only' ) == $queryPage->name() ) { + if ( !$this->hasOption( 'only' ) || $this->getOption( 'only' ) == $queryPage->getName() ) { $this->output( sprintf( '%-30s ', $special ) ); if ( $queryPage->isExpensive() ) { $t1 = explode( ' ', microtime() );