Skip to:
Content
Pages
Categories
Search
Top
Bottom

Re: Some questions about BuddyPress friendships

I’m using the BP function.
It is the former indeed, and I managed to trace the input down to $wpdb->query (if avoid using prepare) or to prepare, to see that it doesn’t work (with prepare the $args = func_get_args() gets nothing as parameter even though I checked they are correct the second is wrong in that line I posted above).

Anyhow here is the result:
SELECT id, is_confirmed FROM wp_bp_friends WHERE (initiator_user_id = 0 AND friend_user_id = 0) OR (initiator_user_id = 0 AND friend_user_id = 0)
This is what I get printed out. If I inspect the values $loggedin_userid, $possible_friend_userid, $possible_friend_userid, $loggedin_userid they have the correct values.
In prepare the problem is this line “$args = func_get_args();” that gets wrongly the parameters (inspecting args returns nothing).

Skip to toolbar