Set forgotten api parameters types
authorKrinkle <krinkle@users.mediawiki.org>
Mon, 4 Apr 2011 20:51:41 +0000 (20:51 +0000)
committerKrinkle <krinkle@users.mediawiki.org>
Mon, 4 Apr 2011 20:51:41 +0000 (20:51 +0000)
* (bug 28394) Set forgotten parameters types in ApiUnblock
* (bug 28395) Set forgotten parameters types in ApiParse

RELEASE-NOTES
includes/api/ApiParse.php
includes/api/ApiUnblock.php

index 237f954..2b0dbdf 100644 (file)
@@ -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
index 714a8eb..5faf8f5 100644 (file)
@@ -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,
index d10ca8f..bdafe13 100644 (file)
@@ -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,