* Get an array mapping token names to their handler functions.
* The prototype for a token function is func($user)
* it should return a token or false (permission denied)
+ * @deprecated since 1.24
* @return array Array of tokenname => function
*/
protected function getTokenFunctions() {
}
/**
+ * @deprecated since 1.24
* @param User $user
* @return string
*/
$data[$name]['blockid'] = $row->ipb_id;
$data[$name]['blockedby'] = $row->ipb_by_text;
$data[$name]['blockedbyid'] = $row->ipb_by;
+ $data[$name]['blockedtimestamp'] = wfTimestamp( TS_ISO_8601, $row->ipb_timestamp );
$data[$name]['blockreason'] = $row->ipb_reason;
$data[$name]['blockexpiry'] = $row->ipb_expiry;
}
$result->setIndexedTagName_internal( array( 'query', $this->getModuleName() ), 'user' );
}
- /**
- * Gets all the groups that a user is automatically a member of (implicit groups)
- *
- * @deprecated since 1.20; call User::getAutomaticGroups() directly.
- * @param User $user
- * @return array
- */
- public static function getAutoGroups( $user ) {
- wfDeprecated( __METHOD__, '1.20' );
-
- return $user->getAutomaticGroups();
- }
-
public function getCacheMode( $params ) {
if ( isset( $params['token'] ) ) {
return 'private';
ApiBase::PARAM_ISMULTI => true
),
'token' => array(
+ ApiBase::PARAM_DEPRECATED => true,
ApiBase::PARAM_TYPE => array_keys( $this->getTokenFunctions() ),
ApiBase::PARAM_ISMULTI => true
),