From: Jure Kajzer Date: Thu, 10 Nov 2011 19:49:32 +0000 (+0000) Subject: * fix as per comment on CR r102625#c25856 X-Git-Tag: 1.31.0-rc.0~26586 X-Git-Url: http://git.cyclocoop.org/%24self?a=commitdiff_plain;h=7d5e46ea05d3956241603205f2fbcc46f222a309;p=lhc%2Fweb%2Fwiklou.git * fix as per comment on CR r102625#c25856 --- diff --git a/includes/api/ApiQueryBlocks.php b/includes/api/ApiQueryBlocks.php index 51b97506df..d5e2e6475b 100644 --- a/includes/api/ApiQueryBlocks.php +++ b/includes/api/ApiQueryBlocks.php @@ -130,8 +130,8 @@ class ApiQueryBlocks extends ApiQueryBase { $this->addWhereIf( 'ipb_user != 0', isset( $show['account'] ) ); $this->addWhereIf( 'ipb_user != 0 OR ipb_range_end > ipb_range_start', isset( $show['!ip'] ) ); $this->addWhereIf( 'ipb_user = 0 AND ipb_range_end = ipb_range_start', isset( $show['ip'] ) ); - $this->addWhereIf( "ipb_expiry = '".$db->getInfinity()."'", isset( $show['!temp'] ) ); - $this->addWhereIf( "ipb_expiry != '".$db->getInfinity()."'", isset( $show['temp'] ) ); + $this->addWhereIf( 'ipb_expiry = '.$db->addQuotes($db->getInfinity(), isset( $show['!temp'] ) ); + $this->addWhereIf( 'ipb_expiry != '.$db->addQuotes($db->getInfinity(), isset( $show['temp'] ) ); $this->addWhereIf( "ipb_range_end = ipb_range_start", isset( $show['!range'] ) ); $this->addWhereIf( "ipb_range_end > ipb_range_start", isset( $show['range'] ) ); }