Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion WatchAnalyticsUser.php
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ public function getPendingWatches() {
null // array( 'u' => array( 'LEFT JOIN', 'u.user-id=w.wl_user' ) )
);
$this->pendingWatches = [];
while ( $row = $dbr->fetchRow( $res ) ) {
while ( $row = $res->fetchRow() ) {

// $title = Title::newFromText( $row['title_text'], $row['notification_timestamp'] );
$this->pendingWatches[] = $row;
Expand Down
4 changes: 2 additions & 2 deletions includes/PendingReview.php
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,7 @@ public static function getPendingReviewsList( User $user, $limit, $offset ) {

$pending = [];

while ( $row = $dbr->fetchRow( $watchResult ) ) {
while ( $row = $watchResult->fetchRow() ) {

$pending[] = new self( $row );

Expand Down Expand Up @@ -249,7 +249,7 @@ public static function getPendingReview( User $user, Title $title ) {

$pending = [];

while ( $row = $dbr->fetchRow( $watchResult ) ) {
while ( $row = $watchResult->fetchRow() ) {

$pending[] = new self( $row );

Expand Down
2 changes: 1 addition & 1 deletion includes/UserWatchesQuery.php
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ public function getUserWatchStats( User $user ) {
$qInfo['join_conds']
);

$row = $dbr->fetchRow( $res );
$row = $res->fetchRow();

// if user doesn't have any pages in watchlist, then no data will be
// returned by this query. Create a "blank" row instead.
Expand Down
4 changes: 2 additions & 2 deletions includes/WatchAnalyticsParserFunctions.php
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ public static function renderUnderwatchedCategories( &$parser, $frame, $args ) {
$output .= "! Category !! Number of Under-watched pages\n";

$categories = [];
while ( $row = $dbr->fetchObject( $result ) ) {
while ( $row = $result->fetchObject() ) {
$pageCategories = explode( ';', $row->categories );

foreach ( $pageCategories as $cat ) {
Expand Down Expand Up @@ -189,7 +189,7 @@ public static function renderWatchersNeeded( &$parser, $frame, $args ) {

$result = $dbr->query( $query );
$output = '';
while ( $row = $dbr->fetchObject( $result ) ) {
while ( $row = $result->fetchObject() ) {
// $title = Title::makeTitle( $row->page_namespace, $row->page_title );
// $watchURL = $title->getFullURL( array( 'action' => 'watch' ) );
// $output .= "* [[$title]] - '''[$watchURL watch]'''\n";
Expand Down
2 changes: 1 addition & 1 deletion maintenance/forgivePendingReviews.php
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ public function execute() {
$result = $dbw->query( $query );
$success = print_r( $result, true );
// $count = 0;
// while ( $row = $dbw->fetchObject( $result ) ) {
// while ( $row = $result->fetchObject() ) {
// $count++;
// $this->output( "\n{$row->pending_since}: {$row->user_name}: {$row->title}" );
// }
Expand Down
2 changes: 1 addition & 1 deletion specials/SpecialPageStatistics.php
Original file line number Diff line number Diff line change
Expand Up @@ -263,7 +263,7 @@ public function pageChart() {
);

$data = [];
while ( $row = $dbr->fetchObject( $res ) ) {
while ( $row = $res->fetchObject() ) {
$data[ $row->timestamp ] = $row->num_reviewed;
}

Expand Down
2 changes: 1 addition & 1 deletion specials/SpecialWatchAnalytics.php
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ public function getPageHeader() {
INNER JOIN page ON page.page_namespace = watchlist.wl_namespace AND page.page_title = watchlist.wl_title;
' );

$allWikiData = $db->fetchRow( $res );
$allWikiData = $res->fetchRow();

list( $watches, $pending, $percent ) = [
$allWikiData['num_watches'],
Expand Down