r79651 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r79650‎ | r79651 | r79652 >
Date:16:37, 5 January 2011
Author:philip
Status:ok (Comments)
Tags:
Comment:
Follow r79649 and r79650. Errrr, remove the redundant minus
Modified paths:
  • /trunk/phase3/includes/api/ApiOpenSearch.php (modified) (history)

Diff [purge]

Index: trunk/phase3/includes/api/ApiOpenSearch.php
@@ -72,7 +72,7 @@
7373 $_srchres = PrefixSearch::titleSearch( $fbsearch, $fblimit,
7474 $namespaces );
7575 $srchres = array_merge( $srchres, $_srchres );
76 - $fblimit -= - count( $_srchres );
 76+ $fblimit -= count( $_srchres );
7777 if ( $fblimit == 0 ) {
7878 break;
7979 }

Follow-up revisions

RevisionCommit summaryAuthorDate
r797201.17: MFT r79578, r79591, r79593, r79595, r79649, r79650, r79651, r79653, r79...catrope14:48, 6 January 2011

Past revisions this follows-up on

RevisionCommit summaryAuthorDate
r79649Add fallback languages support for ApiOpenSearch.philip16:21, 5 January 2011
r79650follow r79649, move the in-block assignment outside.philip16:30, 5 January 2011

Comments

#Comment by Liangent (talk | contribs)   13:37, 9 January 2011
-					$fblimit -= - count( $_srchres );
+					$fblimit -= count( $_srchres );
 					if ( $fblimit == 0 ) {

Isn't this identical to if ( $fblimit == count( $_srchres ) ) {?

#Comment by Catrope (talk | contribs)   14:57, 9 January 2011

No, because we also need to lower $fblimit for the next iteration.

Status & tagging log