http://www.mediawiki.org/wiki/Special:Code/MediaWiki/65313

Revision: 65313
Author:   catrope
Date:     2010-04-20 13:58:21 +0000 (Tue, 20 Apr 2010)

Log Message:
-----------
1.16wmf4: Revert r64778, merge the almost equivalent but better r64454 from 
trunk

Modified Paths:
--------------
    branches/wmf/1.16wmf4/includes/api/ApiBase.php

Property Changed:
----------------
    branches/wmf/1.16wmf4/includes/api/


Property changes on: branches/wmf/1.16wmf4/includes/api
___________________________________________________________________
Modified: svn:mergeinfo
   - /branches/REL1_15/phase3/includes/api:51646
/branches/sqlite/includes/api:58211-58321
/branches/wmf-deployment/includes/api:53381,59952,60970
/trunk/phase3/includes/api:63549,63764,63897-63901
   + /branches/REL1_15/phase3/includes/api:51646
/branches/sqlite/includes/api:58211-58321
/branches/wmf-deployment/includes/api:53381,59952,60970
/trunk/phase3/includes/api:63549,63764,63897-63901,64454

Modified: branches/wmf/1.16wmf4/includes/api/ApiBase.php
===================================================================
--- branches/wmf/1.16wmf4/includes/api/ApiBase.php      2010-04-20 13:52:22 UTC 
(rev 65312)
+++ branches/wmf/1.16wmf4/includes/api/ApiBase.php      2010-04-20 13:58:21 UTC 
(rev 65313)
@@ -475,8 +475,10 @@
                $params = $this->getFinalParams();
                $results = array();
 
-               foreach ( (array)$params as $paramName => $paramSettings ) {
-                       $results[$paramName] = $this->getParameterFromSettings( 
$paramName, $paramSettings, $parseLimit );
+               if($params) {                   /* getFinalParams() can return 
false */
+                       foreach ( $params as $paramName => $paramSettings ) {
+                               $results[$paramName] = 
$this->getParameterFromSettings( $paramName, $paramSettings, $parseLimit );
+                       }
                }
 
                return $results;



_______________________________________________
MediaWiki-CVS mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs

Reply via email to