mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-03-31 10:44:26 +00:00
Add LIMIT 1 to some of our gets.
git-svn-id: https://develop.svn.wordpress.org/trunk@3012 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -37,7 +37,7 @@ function get_userdata( $user_id ) {
|
||||
if ( $user )
|
||||
return $user;
|
||||
|
||||
if ( !$user = $wpdb->get_row("SELECT * FROM $wpdb->users WHERE ID = '$user_id'") )
|
||||
if ( !$user = $wpdb->get_row("SELECT * FROM $wpdb->users WHERE ID = '$user_id' LIMIT 1") )
|
||||
return false;
|
||||
|
||||
$metavalues = $wpdb->get_results("SELECT meta_key, meta_value FROM $wpdb->usermeta WHERE user_id = '$user_id'");
|
||||
|
||||
Reference in New Issue
Block a user