Hello Tosin,
Thank you for posting. Please try the following code:
add_filter( 'bp_profile_visibility_visiility_levels', function ( $visibilities ) { if ( function_exists( 'bp_follow_is_following' ) && ! isset( $visibilities['followers'] ) ) { $visibilities['followers'] = __( 'My Followers' ); } return $visibilities; } ); add_filter( 'bp_profile_visibility_is_visible_profile', function ( $can_see, $user_id, $visitor_id ) { if ( function_exists( 'bp_follow_is_following' ) ) { $privacy = bp_profile_visibility_get_settings( $user_id, 'bp_profile_visibility' ); if ( 'followers' === $privacy ) { $can_see = bp_follow_is_following( array( 'leader_id' => $user_id, 'follower_id' => $visitor_id, ) ); } } return $can_see; }, 10, 3 );
Please let me know if it works or not.
Regards
Ravi
Viewing 4 posts - 1 through 4 (of 4 total)
You must be logged in to reply to this topic.
This topic is: resolved