r62514 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r62513‎ | r62514 | r62515 >
Date:12:23, 15 February 2010
Author:catrope
Status:ok
Tags:
Comment:
wmf-deployment: MFT r62513
Modified paths:
  • /branches/wmf-deployment/includes/api/ApiQueryBlocks.php (modified) (history)

Diff [purge]

Index: branches/wmf-deployment/includes/api/ApiQueryBlocks.php
@@ -63,27 +63,29 @@
6464 $titles = $pageSet->getTitles();
6565 $data = array();
6666
67 - $this->addTables('ipblocks');
68 - if($fld_id)
69 - $this->addFields('ipb_id');
70 - if($fld_user)
71 - $this->addFields(array('ipb_address', 'ipb_user', 'ipb_auto'));
72 - if($fld_by)
 67+ $this->addTables( 'ipblocks' );
 68+ $this->addFields( 'ipb_auto' );
 69+
 70+ if ( $fld_id )
 71+ $this->addFields( 'ipb_id' );
 72+ if ( $fld_user )
 73+ $this->addFields( array( 'ipb_address', 'ipb_user' ) );
 74+ if ( $fld_by )
7375 {
7476 $this->addTables('user');
7577 $this->addFields(array('ipb_by', 'user_name'));
7678 $this->addWhere('user_id = ipb_by');
7779 }
78 - if($fld_timestamp)
79 - $this->addFields('ipb_timestamp');
80 - if($fld_expiry)
81 - $this->addFields('ipb_expiry');
82 - if($fld_reason)
83 - $this->addFields('ipb_reason');
84 - if($fld_range)
85 - $this->addFields(array('ipb_range_start', 'ipb_range_end'));
86 - if($fld_flags)
87 - $this->addFields(array('ipb_auto', 'ipb_anon_only', 'ipb_create_account', 'ipb_enable_autoblock', 'ipb_block_email', 'ipb_deleted', 'ipb_allow_usertalk'));
 80+ if ( $fld_timestamp )
 81+ $this->addFields( 'ipb_timestamp' );
 82+ if ( $fld_expiry )
 83+ $this->addFields( 'ipb_expiry' );
 84+ if ( $fld_reason )
 85+ $this->addFields( 'ipb_reason' );
 86+ if ( $fld_range )
 87+ $this->addFields( array( 'ipb_range_start', 'ipb_range_end' ) );
 88+ if ( $fld_flags )
 89+ $this->addFields( array( 'ipb_anon_only', 'ipb_create_account', 'ipb_enable_autoblock', 'ipb_block_email', 'ipb_deleted', 'ipb_allow_usertalk' ) );
8890
8991 $this->addOption('LIMIT', $params['limit'] + 1);
9092 $this->addWhereRange('ipb_timestamp', $params['dir'], $params['start'], $params['end']);

Past revisions this follows-up on

RevisionCommit summaryAuthorDate
r62513Fix r62511: always select ipb_auto fieldcatrope12:20, 15 February 2010

Status & tagging log