From: umherirrender Date: Thu, 27 Dec 2012 13:54:16 +0000 (+0100) Subject: Use NS_* constant for default namespace in api X-Git-Tag: 1.31.0-rc.0~21205 X-Git-Url: http://git.cyclocoop.org/%24href?a=commitdiff_plain;h=2de5c3e06cf4f4076f347397f4395c4917feb70c;p=lhc%2Fweb%2Fwiklou.git Use NS_* constant for default namespace in api Change-Id: Ic46e7fe1877c4067b1b6bbea71216c0cdf594cb2 --- diff --git a/includes/api/ApiQueryAllLinks.php b/includes/api/ApiQueryAllLinks.php index da4840f074..0420838a92 100644 --- a/includes/api/ApiQueryAllLinks.php +++ b/includes/api/ApiQueryAllLinks.php @@ -183,7 +183,7 @@ class ApiQueryAllLinks extends ApiQueryGeneratorBase { ) ), 'namespace' => array( - ApiBase::PARAM_DFLT => 0, + ApiBase::PARAM_DFLT => NS_MAIN, ApiBase::PARAM_TYPE => 'namespace' ), 'limit' => array( diff --git a/includes/api/ApiQueryAllPages.php b/includes/api/ApiQueryAllPages.php index 16cc31d291..a5abae76ab 100644 --- a/includes/api/ApiQueryAllPages.php +++ b/includes/api/ApiQueryAllPages.php @@ -226,7 +226,7 @@ class ApiQueryAllPages extends ApiQueryGeneratorBase { 'to' => null, 'prefix' => null, 'namespace' => array( - ApiBase::PARAM_DFLT => 0, + ApiBase::PARAM_DFLT => NS_MAIN, ApiBase::PARAM_TYPE => 'namespace', ), 'filterredir' => array( diff --git a/includes/api/ApiQueryDeletedrevs.php b/includes/api/ApiQueryDeletedrevs.php index e69ccbd6f5..8903e4686f 100644 --- a/includes/api/ApiQueryDeletedrevs.php +++ b/includes/api/ApiQueryDeletedrevs.php @@ -307,7 +307,7 @@ class ApiQueryDeletedrevs extends ApiQueryBase { ), 'namespace' => array( ApiBase::PARAM_TYPE => 'namespace', - ApiBase::PARAM_DFLT => 0, + ApiBase::PARAM_DFLT => NS_MAIN, ), 'limit' => array( ApiBase::PARAM_DFLT => 10, diff --git a/includes/api/ApiQuerySearch.php b/includes/api/ApiQuerySearch.php index 364433d598..cfd08a88a2 100644 --- a/includes/api/ApiQuerySearch.php +++ b/includes/api/ApiQuerySearch.php @@ -205,7 +205,7 @@ class ApiQuerySearch extends ApiQueryGeneratorBase { ApiBase::PARAM_REQUIRED => true ), 'namespace' => array( - ApiBase::PARAM_DFLT => 0, + ApiBase::PARAM_DFLT => NS_MAIN, ApiBase::PARAM_TYPE => 'namespace', ApiBase::PARAM_ISMULTI => true, ),