bp_get_potential_friend_id

  • apply_filters( 'bp_get_potential_friend_id', (int)$user_id )

    Source Reference:

    • Component: BuddyPress :: bp-friends
      File: /bp-friends/bp-friends-template.php :: Trac Source Line: 272
      	 */
      	function bp_get_potential_friend_id( $user_id = 0 ) {
      		global $bp, $friends_template;
      
      		if ( empty( $user_id ) && isset( $friends_template->friendship->friend ) )
      			$user_id = $friends_template->friendship->friend->id;
      		else if ( empty( $user_id ) && !isset( $friends_template->friendship->friend ) )
      			$user_id = $bp->displayed_user->id;
      
      		return apply_filters( 'bp_get_potential_friend_id', (int)$user_id );
      	}
      
      /**
       * bp_is_friend( $user_id )
       *
       * Returns - 'is_friend', 'not_friends', 'pending'
       *
       * @global object $bp
       * @param int $potential_friend_id
       * @return string
      

Comments are closed.