diff options
author | Pierre Schmitz <pierre@archlinux.de> | 2015-12-20 09:00:55 +0100 |
---|---|---|
committer | Pierre Schmitz <pierre@archlinux.de> | 2015-12-20 09:00:55 +0100 |
commit | a2190ac74dd4d7080b12bab90e552d7aa81209ef (patch) | |
tree | 8b31f38de9882d18df54cf8d9e0de74167a094eb /includes/api/ApiQueryAllUsers.php | |
parent | 15e69f7b20b6596b9148030acce5b59993b95a45 (diff) | |
parent | 257401d8b2cf661adf36c84b0e3fd1cf85e33c22 (diff) |
Merge branch 'mw-1.26'
Diffstat (limited to 'includes/api/ApiQueryAllUsers.php')
-rw-r--r-- | includes/api/ApiQueryAllUsers.php | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/includes/api/ApiQueryAllUsers.php b/includes/api/ApiQueryAllUsers.php index 0cea84f8..eb3e5537 100644 --- a/includes/api/ApiQueryAllUsers.php +++ b/includes/api/ApiQueryAllUsers.php @@ -41,7 +41,7 @@ class ApiQueryAllUsers extends ApiQueryBase { * @return string */ private function getCanonicalUserName( $name ) { - return str_replace( '_', ' ', $name ); + return strtr( $name, '_', ' ' ); } public function execute() { @@ -235,14 +235,14 @@ class ApiQueryAllUsers extends ApiQueryBase { } $data = array( - 'userid' => $row->user_id, + 'userid' => (int)$row->user_id, 'name' => $row->user_name, ); if ( $fld_blockinfo && !is_null( $row->ipb_by_text ) ) { - $data['blockid'] = $row->ipb_id; + $data['blockid'] = (int)$row->ipb_id; $data['blockedby'] = $row->ipb_by_text; - $data['blockedbyid'] = $row->ipb_by; + $data['blockedbyid'] = (int)$row->ipb_by; $data['blockedtimestamp'] = wfTimestamp( TS_ISO_8601, $row->ipb_timestamp ); $data['blockreason'] = $row->ipb_reason; $data['blockexpiry'] = $row->ipb_expiry; @@ -340,7 +340,8 @@ class ApiQueryAllUsers extends ApiQueryBase { 'rights', 'editcount', 'registration' - ) + ), + ApiBase::PARAM_HELP_MSG_PER_VALUE => array(), ), 'limit' => array( ApiBase::PARAM_DFLT => 10, |