More query reduction.

git-svn-id: http://svn.automattic.com/wordpress/trunk@1184 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
saxmatt
2004-04-26 19:18:25 +00:00
parent 788f328d6b
commit f8e2f4f2f4
3 changed files with 5 additions and 5 deletions

View File

@@ -175,8 +175,8 @@ function get_currentuserinfo() { // a bit like get_userdata(), on steroids
}
function get_userdata($userid) {
global $wpdb, $cache_userdata, $tableusers;
if ( empty($cache_userdata[$userid]) ) {
global $wpdb, $cache_authors, $tableusers;
if ( empty($cache_authors[$userid]) ) {
$user = $wpdb->get_row("SELECT * FROM $tableusers WHERE ID = '$userid'");
$user->user_nickname = stripslashes($user->user_nickname);
$user->user_firstname = stripslashes($user->user_firstname);