From 2de5c3e06cf4f4076f347397f4395c4917feb70c Mon Sep 17 00:00:00 2001 From: umherirrender Date: Thu, 27 Dec 2012 14:54:16 +0100 Subject: [PATCH] Use NS_* constant for default namespace in api Change-Id: Ic46e7fe1877c4067b1b6bbea71216c0cdf594cb2 --- includes/api/ApiQueryAllLinks.php | 2 +- includes/api/ApiQueryAllPages.php | 2 +- includes/api/ApiQueryDeletedrevs.php | 2 +- includes/api/ApiQuerySearch.php | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) 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, ), -- 2.20.1