requested.
* Special:Recentchangeslinked will now include upload log entries
* (bug 41281) Fixed ugly output if file size could not be extracted for multi-page media.
+* (bug 50315) list=logevents API module will now output log entries by anonymous users.
=== API changes in 1.22 ===
* (bug 25553) The JSON output formatter now leaves forward slashes unescaped
$this->addTables( array( 'logging', 'user', 'page' ) );
$this->addOption( 'STRAIGHT_JOIN' );
$this->addJoinConds( array(
- 'user' => array( 'JOIN',
+ 'user' => array( 'LEFT JOIN',
'user_id=log_user' ),
'page' => array( 'LEFT JOIN',
array( 'log_namespace=page_namespace',
) );
$this->addFieldsIf( array( 'log_id', 'page_id' ), $this->fld_ids );
- $this->addFieldsIf( array( 'log_user', 'user_name' ), $this->fld_user );
- $this->addFieldsIf( 'user_id', $this->fld_userid );
+ $this->addFieldsIf( array( 'log_user', 'log_user_text', 'user_name' ), $this->fld_user );
+ $this->addFieldsIf( 'log_user', $this->fld_userid );
$this->addFieldsIf( array( 'log_namespace', 'log_title' ), $this->fld_title || $this->fld_parsedcomment );
$this->addFieldsIf( 'log_comment', $this->fld_comment || $this->fld_parsedcomment );
$this->addFieldsIf( 'log_params', $this->fld_details );
$vals['userhidden'] = '';
} else {
if ( $this->fld_user ) {
- $vals['user'] = $row->user_name;
+ $vals['user'] = $row->user_name === null ? $row->log_user_text : $row->user_name;
}
if ( $this->fld_userid ) {
- $vals['userid'] = $row->user_id;
+ $vals['userid'] = $row->log_user;
}
if ( !$row->log_user ) {