diff options
Diffstat (limited to 'includes/api/ApiParamInfo.php')
-rw-r--r-- | includes/api/ApiParamInfo.php | 16 |
1 files changed, 12 insertions, 4 deletions
diff --git a/includes/api/ApiParamInfo.php b/includes/api/ApiParamInfo.php index 77ce514f..2cf044cf 100644 --- a/includes/api/ApiParamInfo.php +++ b/includes/api/ApiParamInfo.php @@ -86,12 +86,12 @@ class ApiParamInfo extends ApiBase { $retval['classname'] = get_class($obj); $retval['description'] = (is_array($obj->getDescription()) ? implode("\n", $obj->getDescription()) : $obj->getDescription()); $retval['prefix'] = $obj->getModulePrefix(); - $allowedParams = $obj->getAllowedParams(); + $allowedParams = $obj->getFinalParams(); if(!is_array($allowedParams)) return $retval; $retval['parameters'] = array(); - $paramDesc = $obj->getParamDescription(); - foreach($obj->getAllowedParams() as $n => $p) + $paramDesc = $obj->getFinalParamDescription(); + foreach($allowedParams as $n => $p) { $a = array('name' => $n); if(!is_array($p)) @@ -111,7 +111,15 @@ class ApiParamInfo extends ApiBase { $a['default'] = $p[ApiBase::PARAM_DFLT]; if(isset($p[ApiBase::PARAM_ISMULTI])) if($p[ApiBase::PARAM_ISMULTI]) + { $a['multi'] = ''; + $a['limit'] = $this->getMain()->canApiHighLimits() ? + ApiBase::LIMIT_SML2 : + ApiBase::LIMIT_SML1; + } + if(isset($p[ApiBase::PARAM_ALLOW_DUPLICATES])) + if($p[ApiBase::PARAM_ALLOW_DUPLICATES]) + $a['allowsduplicates'] = ''; if(isset($p[ApiBase::PARAM_TYPE])) { $a['type'] = $p[ApiBase::PARAM_TYPE]; @@ -161,6 +169,6 @@ class ApiParamInfo extends ApiBase { } public function getVersion() { - return __CLASS__ . ': $Id: ApiParamInfo.php 35098 2008-05-20 17:13:28Z ialex $'; + return __CLASS__ . ': $Id: ApiParamInfo.php 41653 2008-10-04 15:03:03Z catrope $'; } } |