diff --git a/bp-core/bp-core-classes.php b/bp-core/bp-core-classes.php
index 90442de..1bb9f43 100644
|
a
|
b
|
class BP_User_Query { |
| 302 | 302 | $friend_ids = $wpdb->escape( implode( ',', (array) $friend_ids ) ); |
| 303 | 303 | |
| 304 | 304 | if ( !empty( $friend_ids ) ) { |
| 305 | | $sql['where'][] = "u.{$this->uid_name} NOT IN ({$friend_ids})"; |
| 306 | | } else { |
| 307 | | // If the user has no friends, make sure the query returns null |
| | 305 | $sql['where'][] = "u.{$this->uid_name} IN ({$friend_ids})"; |
| | 306 | |
| | 307 | // If the user has no friends, and we're not including specific users, make sure the query returns null |
| | 308 | } elseif ( empty( $include ) ) { |
| 308 | 309 | $sql['where'][] = $this->no_results['where']; |
| 309 | 310 | } |
| 310 | 311 | } |