diff -r def792dd9b1b -r 1e2c9819ede3 includes/log.php --- a/includes/log.php Fri Dec 18 09:39:18 2009 -0500 +++ b/includes/log.php Fri Dec 18 19:06:49 2009 -0500 @@ -160,8 +160,10 @@ $limit = ( $page_size > 0 ) ? "\n LIMIT $page_size OFFSET $offset" : ''; else $limit = ( $page_size > 0 ) ? "\n LIMIT $offset, $page_size" : ''; - $columns = ( $just_page_count ) ? 'COUNT(*)' : 'log_id, action, page_id, namespace, CHAR_LENGTH(page_text) AS revision_size, author, time_id, edit_summary, minor_edit'; + $columns = ( $just_page_count ) ? 'COUNT(*)' : 'log_id, action, page_id, namespace, CHAR_LENGTH(page_text) AS revision_size, author, author_uid, u.username, time_id, edit_summary, minor_edit'; $sql = 'SELECT ' . $columns . ' FROM ' . table_prefix . "logs AS l\n" + . " LEFT JOIN " . table_prefix . "users AS u\n" + . " ON ( u.user_id = l.author_uid OR u.user_id IS NULL )\n" . " WHERE log_type = 'page' AND is_draft != 1$where_extra\n" . " GROUP BY log_id, action, page_id, namespace, page_text, author, time_id, edit_summary, minor_edit\n" . " ORDER BY time_id DESC $limit;"; @@ -386,14 +388,15 @@ } // link to userpage - $cls = ( isPage($paths->nslist['User'] . $row['author']) ) ? '' : ' class="wikilink-nonexistent"'; - $rank_info = $session->get_user_rank($row['author']); - $html .= '' . htmlspecialchars($row['author']) . ' '; + $real_username = $row['author_uid'] > 1 && !empty($row['username']) ? $row['username'] : $row['author']; + $cls = ( isPage($paths->nslist['User'] . $real_username) ) ? '' : ' class="wikilink-nonexistent"'; + $rank_info = $session->get_user_rank($row['author_uid']); + $html .= '' . htmlspecialchars($real_username) . ' '; $html .= '('; - $html .= ''; + $html .= ''; $html .= $lang->get('pagetools_rc_btn_pm'); $html .= ', '; - $html .= ''; + $html .= ''; $html .= $lang->get('pagetools_rc_btn_usertalk'); $html .= ''; $html .= ') . . ';