(bug 18710) Fixed internal error with empty parameter in ApiParamInfo
authorChad Horohoe <demon@users.mediawiki.org>
Thu, 7 May 2009 20:09:45 +0000 (20:09 +0000)
committerChad Horohoe <demon@users.mediawiki.org>
Thu, 7 May 2009 20:09:45 +0000 (20:09 +0000)
RELEASE-NOTES
includes/api/ApiParamInfo.php

index 8d7379b..4b24b16 100644 (file)
@@ -133,6 +133,7 @@ it from source control: http://www.mediawiki.org/wiki/Download_from_SVN
 * Added PHP and database version to meta=siteinfo output
 * (bug 18533) Add readonly message to meta=siteinfo output
 * (bug 18518) Add clprop=hidden to prop=categories
+* (bug 18710) Fixed internal error with empty parameter in ApiParamInfo
 
 === Languages updated in 1.16 ===
 
index e8f7b2a..4b2a263 100644 (file)
@@ -46,6 +46,7 @@ class ApiParamInfo extends ApiBase {
                if(is_array($params['modules']))
                {
                        $modArr = $this->getMain()->getModules();
+                       $r['modules'] = array();
                        foreach($params['modules'] as $m)
                        {
                                if(!isset($modArr[$m]))
@@ -63,6 +64,7 @@ class ApiParamInfo extends ApiBase {
                if(is_array($params['querymodules']))
                {
                        $qmodArr = $queryObj->getModules();
+                       $r['querymodules'] = array();
                        foreach($params['querymodules'] as $qm)
                        {
                                if(!isset($qmodArr[$qm]))