From: Krinkle Date: Mon, 4 Apr 2011 20:51:41 +0000 (+0000) Subject: Set forgotten api parameters types X-Git-Tag: 1.31.0-rc.0~31020 X-Git-Url: http://git.cyclocoop.org/%40spipnet%40?a=commitdiff_plain;h=d3eec98cb79fbee8193e8c61b38e98d45a755325;p=lhc%2Fweb%2Fwiklou.git Set forgotten api parameters types * (bug 28394) Set forgotten parameters types in ApiUnblock * (bug 28395) Set forgotten parameters types in ApiParse --- diff --git a/RELEASE-NOTES b/RELEASE-NOTES index 237f9545e6..2b0dbdf944 100644 --- a/RELEASE-NOTES +++ b/RELEASE-NOTES @@ -217,6 +217,8 @@ PHP if you have not done so prior to upgrading MediaWiki. * (bug 27893) Edit-on-doubleclick now applies only on view and purge actions; no longer triggers unexpectedly on delete, history etc. * (bug 28417) Fix PHP notice when importing revision without a listed id +* (bug 28394) Set forgotten parameters types in ApiUnblock +* (bug 28395) Set forgotten parameters types in ApiParse === API changes in 1.18 === * (bug 26339) Throw warning when truncating an overlarge API result diff --git a/includes/api/ApiParse.php b/includes/api/ApiParse.php index 714a8ebba7..5faf8f5ede 100644 --- a/includes/api/ApiParse.php +++ b/includes/api/ApiParse.php @@ -483,9 +483,13 @@ class ApiParse extends ApiBase { 'text' => null, 'summary' => null, 'page' => null, - 'pageid' => null, + 'pageid' => array( + ApiBase::PARAM_TYPE => 'integer', + ), 'redirects' => false, - 'oldid' => null, + 'oldid' => array( + ApiBase::PARAM_TYPE => 'integer', + ), 'prop' => array( ApiBase::PARAM_DFLT => 'text|langlinks|categories|links|templates|images|externallinks|sections|revid|displaytitle', ApiBase::PARAM_ISMULTI => true, diff --git a/includes/api/ApiUnblock.php b/includes/api/ApiUnblock.php index d10ca8f07d..bdafe135c5 100644 --- a/includes/api/ApiUnblock.php +++ b/includes/api/ApiUnblock.php @@ -98,7 +98,9 @@ class ApiUnblock extends ApiBase { public function getAllowedParams() { return array( - 'id' => null, + 'id' => array( + ApiBase::PARAM_TYPE => 'integer', + ), 'user' => null, 'token' => null, 'gettoken' => false,