r102677 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r102676‎ | r102677 | r102678 >
Date:19:49, 10 November 2011
Author:freakolowsky
Status:ok (Comments)
Tags:
Comment:
* fix as per comment on CR r102625#c25856
Modified paths:
  • /trunk/phase3/includes/api/ApiQueryBlocks.php (modified) (history)

Diff [purge]

Index: trunk/phase3/includes/api/ApiQueryBlocks.php
@@ -130,8 +130,8 @@
131131 $this->addWhereIf( 'ipb_user != 0', isset( $show['account'] ) );
132132 $this->addWhereIf( 'ipb_user != 0 OR ipb_range_end > ipb_range_start', isset( $show['!ip'] ) );
133133 $this->addWhereIf( 'ipb_user = 0 AND ipb_range_end = ipb_range_start', isset( $show['ip'] ) );
134 - $this->addWhereIf( "ipb_expiry = '".$db->getInfinity()."'", isset( $show['!temp'] ) );
135 - $this->addWhereIf( "ipb_expiry != '".$db->getInfinity()."'", isset( $show['temp'] ) );
 134+ $this->addWhereIf( 'ipb_expiry = '.$db->addQuotes($db->getInfinity(), isset( $show['!temp'] ) );
 135+ $this->addWhereIf( 'ipb_expiry != '.$db->addQuotes($db->getInfinity(), isset( $show['temp'] ) );
136136 $this->addWhereIf( "ipb_range_end = ipb_range_start", isset( $show['!range'] ) );
137137 $this->addWhereIf( "ipb_range_end > ipb_range_start", isset( $show['range'] ) );
138138 }

Follow-up revisions

RevisionCommit summaryAuthorDate
r102687* sry about that :S ... 10x Aaronfreakolowsky20:50, 10 November 2011

Past revisions this follows-up on

RevisionCommit summaryAuthorDate
r102625* Added getInfinity to DatabaseOracle...freakolowsky07:41, 10 November 2011

Comments

#Comment by Aaron Schulz (talk | contribs)   20:04, 10 November 2011

Hate to nag, but this is a syntax error, the addQuotes() call isn't closed with a parentheses :)

Status & tagging log