From: Roan Kattouw Date: Mon, 25 Feb 2008 22:11:56 +0000 (+0000) Subject: (bug 13154) Adding subpage info to meta=siteinfo&siprop=namespaces. Also adding RELEA... X-Git-Tag: 1.31.0-rc.0~49347 X-Git-Url: https://git.cyclocoop.org/%27.%24link.%27?a=commitdiff_plain;h=e0af6c66a92fa933f03a259c5725a9f7d3039437;p=lhc%2Fweb%2Fwiklou.git (bug 13154) Adding subpage info to meta=siteinfo&siprop=namespaces. Also adding RELEASE-NOTES entry for r31260 --- diff --git a/RELEASE-NOTES b/RELEASE-NOTES index d41b763279..67a107c3fc 100644 --- a/RELEASE-NOTES +++ b/RELEASE-NOTES @@ -48,6 +48,8 @@ it from source control: http://www.mediawiki.org/wiki/Download_from_SVN * Fixing main page display in meta=siteinfo * (bug 13128) Add patrolled flag to list=recentchanges +* Implemented {bl,ei,iu}redirect (lists links through redirects as well) +* (bug 13154) Introducing subpages flag to meta=siteinfo&siprop=namespaces === Languages updated in 1.13 === diff --git a/includes/api/ApiQuerySiteinfo.php b/includes/api/ApiQuerySiteinfo.php index 8e4752a9dd..5d51582990 100644 --- a/includes/api/ApiQuerySiteinfo.php +++ b/includes/api/ApiQuerySiteinfo.php @@ -93,7 +93,7 @@ class ApiQuerySiteinfo extends ApiQueryBase { } protected function appendNamespaces($property) { - global $wgContLang; + global $wgContLang, $wgNamespacesWithSubpages; $data = array (); foreach ($wgContLang->getFormattedNamespaces() as $ns => $title) { @@ -101,6 +101,8 @@ class ApiQuerySiteinfo extends ApiQueryBase { 'id' => $ns ); ApiResult :: setContent($data[$ns], $title); + if(@$wgNamespacesWithSubpages[$ns]) + $data[$ns]['subpages'] = ''; } $this->getResult()->setIndexedTagName($data, 'ns');