From 72e90545454c0e014318fa3c81658e035aac58c1 Mon Sep 17 00:00:00 2001 From: Pierre Schmitz Date: Wed, 10 Jun 2009 13:00:47 +0200 Subject: applying patch to version 1.15.0 --- includes/QueryPage.php | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'includes/QueryPage.php') diff --git a/includes/QueryPage.php b/includes/QueryPage.php index 0b587508..1cef31ea 100644 --- a/includes/QueryPage.php +++ b/includes/QueryPage.php @@ -204,7 +204,7 @@ class QueryPage { * Clear the cache and save new results */ function recache( $limit, $ignoreErrors = true ) { - $fname = get_class($this) . '::recache'; + $fname = get_class( $this ) . '::recache'; $dbw = wfGetDB( DB_MASTER ); $dbr = wfGetDB( DB_SLAVE, array( $this->getName(), 'QueryPage::recache', 'vslow' ) ); if ( !$dbw || !$dbr ) { @@ -222,9 +222,9 @@ class QueryPage { $dbw->delete( 'querycache', array( 'qc_type' => $this->getName() ), $fname ); # Do query $sql = $this->getSQL() . $this->getOrder(); - if ($limit !== false) - $sql = $dbr->limitResult($sql, $limit, 0); - $res = $dbr->query($sql, $fname); + if ( $limit !== false ) + $sql = $dbr->limitResult( $sql, $limit, 0 ); + $res = $dbr->query( $sql, $fname ); $num = false; if ( $res ) { $num = $dbr->numRows( $res ); @@ -238,7 +238,7 @@ class QueryPage { $insertSql .= ','; } if ( isset( $row->value ) ) { - $value = $row->value; + $value = intval( $row->value ); // @bug 14414 } else { $value = 0; } -- cgit v1.2.2