About bp_nouveau_current_user_can
- 
		Anyone knows how to filter the “bp_nouveau_current_user_can” function with out affecting the previous set filter? // return is being overwritten by the the next filter. Returns true instead of false. add_filter("bp_nouveau_current_user_can", function( $is_loggedin, $cap, $uid ){ if ( $cap === "publish_activity" ) { return false; } return $is_loggedin; }, 20, 3); // overwiting previous filter. add_filter("bp_nouveau_current_user_can", function( $is_loggedin, $cap, $uid ){ if ( $cap === "comment_activity" ) { return true; } return $is_loggedin; }, 20, 3);Would be great if we can check if current user can do things in specific components. Thanks! 
Viewing 2 replies - 1 through 2 (of 2 total)
	
Viewing 2 replies - 1 through 2 (of 2 total)
	
- You must be logged in to reply to this topic.