diff --git src/bp-friends/bp-friends-functions.php src/bp-friends/bp-friends-functions.php
index ae2efb744..a57374a79 100644
|
|
|
function friends_add_friend( $initiator_userid, $friend_userid, $force_accept =
|
| 42 | 42 | return true; |
| 43 | 43 | } |
| 44 | 44 | |
| | 45 | $initiator_user = get_user_by( 'id', $initiator_userid ); |
| | 46 | $friend_user = get_user_by( 'id', $friend_userid ); |
| | 47 | if ( ! $initiator_user || ! $friend_user ) { |
| | 48 | return false; |
| | 49 | } |
| | 50 | |
| 45 | 51 | // Setup the friendship data. |
| 46 | 52 | $friendship = new BP_Friends_Friendship; |
| 47 | 53 | $friendship->initiator_user_id = (int) $initiator_userid; |