r44676 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r44675‎ | r44676 | r44677 >
Date:17:19, 16 December 2008
Author:soxred93
Status:ok
Tags:
Comment:
* (bug 16672) Add canonical parameter to meta=siteinfo&siprop=namespaces|namespacealiases.
Modified paths:
  • /trunk/phase3/RELEASE-NOTES (modified) (history)
  • /trunk/phase3/includes/api/ApiQuerySiteinfo.php (modified) (history)

Diff [purge]

Index: trunk/phase3/includes/api/ApiQuerySiteinfo.php
@@ -135,8 +135,13 @@
136136 'id' => $ns
137137 );
138138 ApiResult :: setContent( $data[$ns], $title );
139 - if( MWNamespace::hasSubpages($ns) )
 139+ $canonical = Namespace::getCanonicalName( $ns );
 140+
 141+ if( MWNamespace::hasSubpages( $ns ) )
140142 $data[$ns]['subpages'] = '';
 143+
 144+ if( $canonical )
 145+ $data[$ns]['canonical'] = $canonical;
141146 }
142147
143148 $this->getResult()->setIndexedTagName( $data, 'ns' );
Index: trunk/phase3/RELEASE-NOTES
@@ -233,6 +233,7 @@
234234 * (bug 7492) Rights can now be assigned to specific IP addresses and ranges by
235235 using $wgAutopromote (new defines: APCOND_ISIP and APCOND_IPINRANGE)
236236 * Add a 'change block' link to Special:IPBlockList und Special:Log
 237+* (bug 16672) Add canonical parameter to meta=siteinfo&siprop=namespaces|namespacealiases.
237238
238239 === Bug fixes in 1.14 ===
239240

Follow-up revisions

RevisionCommit summaryAuthorDate
r44683Fix for r44676, fix E_NOTICE from having no canonical name associated with a ...mrzman19:59, 16 December 2008
r44769API: Fix up r44676: convert underscores to spaces in canonical names.catrope15:00, 18 December 2008

Status & tagging log