r106763 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r106762‎ | r106763 | r106764 >
Date:07:50, 20 December 2011
Author:maxsem
Status:ok
Tags:
Comment:
Follow-up r97303: sort module names in paraminfo's paraminfo
Modified paths:
  • /trunk/phase3/includes/api/ApiParamInfo.php (modified) (history)

Diff [purge]

Index: trunk/phase3/includes/api/ApiParamInfo.php
@@ -260,21 +260,26 @@
261261 }
262262
263263 public function getAllowedParams() {
264 -
 264+ $modules = array_keys( $this->getMain()->getModules() );
 265+ sort( $modules );
 266+ $querymodules = array_keys( $this->queryObj->getModules() );
 267+ sort( $querymodules );
 268+ $formatmodules = array_keys( $this->getMain()->getFormats() );
 269+ sort( $formatmodules );
265270 return array(
266271 'modules' => array(
267272 ApiBase::PARAM_ISMULTI => true,
268 - ApiBase::PARAM_TYPE => array_keys( $this->getMain()->getModules() ),
 273+ ApiBase::PARAM_TYPE => $modules,
269274 ),
270275 'querymodules' => array(
271276 ApiBase::PARAM_ISMULTI => true,
272 - ApiBase::PARAM_TYPE => array_keys( $this->queryObj->getModules() ),
 277+ ApiBase::PARAM_TYPE => $querymodules,
273278 ),
274279 'mainmodule' => false,
275280 'pagesetmodule' => false,
276281 'formatmodules' => array(
277282 ApiBase::PARAM_ISMULTI => true,
278 - ApiBase::PARAM_TYPE => array_keys( $this->getMain()->getFormats() ),
 283+ ApiBase::PARAM_TYPE => $formatmodules,
279284 )
280285 );
281286 }

Past revisions this follows-up on

RevisionCommit summaryAuthorDate
r97303Give a list of modules to query and action into paraminforeedy18:11, 16 September 2011

Status & tagging log