diff options
Diffstat (limited to 'includes/api/ApiUnblock.php')
-rw-r--r-- | includes/api/ApiUnblock.php | 23 |
1 files changed, 0 insertions, 23 deletions
diff --git a/includes/api/ApiUnblock.php b/includes/api/ApiUnblock.php index ff9ac474..6a739a2f 100644 --- a/includes/api/ApiUnblock.php +++ b/includes/api/ApiUnblock.php @@ -32,10 +32,6 @@ */ class ApiUnblock extends ApiBase { - public function __construct( $main, $action ) { - parent::__construct( $main, $action ); - } - /** * Unblocks the specified user or provides the reason the unblock failed. */ @@ -43,12 +39,6 @@ class ApiUnblock extends ApiBase { $user = $this->getUser(); $params = $this->extractRequestParams(); - if ( $params['gettoken'] ) { - $res['unblocktoken'] = $user->getEditToken(); - $this->getResult()->addValue( null, $this->getModuleName(), $res ); - return; - } - if ( is_null( $params['id'] ) && is_null( $params['user'] ) ) { $this->dieUsageMsg( 'unblock-notarget' ); } @@ -100,10 +90,6 @@ class ApiUnblock extends ApiBase { ), 'user' => null, 'token' => null, - 'gettoken' => array( - ApiBase::PARAM_DFLT => false, - ApiBase::PARAM_DEPRECATED => true, - ), 'reason' => '', ); } @@ -114,7 +100,6 @@ class ApiUnblock extends ApiBase { 'id' => "ID of the block you want to unblock (obtained through list=blocks). Cannot be used together with {$p}user", 'user' => "Username, IP address or IP range you want to unblock. Cannot be used together with {$p}id", 'token' => "An unblock token previously obtained through prop=info", - 'gettoken' => 'If set, an unblock token will be returned, and no other action will be taken', 'reason' => 'Reason for unblock', ); } @@ -122,10 +107,6 @@ class ApiUnblock extends ApiBase { public function getResultProperties() { return array( '' => array( - 'unblocktoken' => array( - ApiBase::PROP_TYPE => 'string', - ApiBase::PROP_NULLABLE => true - ), 'id' => array( ApiBase::PROP_TYPE => 'integer', ApiBase::PROP_NULLABLE => true @@ -178,8 +159,4 @@ class ApiUnblock extends ApiBase { public function getHelpUrls() { return 'https://www.mediawiki.org/wiki/API:Block'; } - - public function getVersion() { - return __CLASS__ . ': $Id$'; - } } |