bp_user_can_create_groups

  • apply_filters( 'bp_user_can_create_groups', $can_create, $restricted )

    Source Reference:

    • Component: BuddyPress :: bp-groups
      File: /bp-groups/bp-groups-template.php :: Trac Source Line: 1983
      	$restricted = (int) bp_get_option( 'bp_restrict_group_creation', 0 );
      
      	// Allow by default
      	$can_create = true;
      
      	// Are regular users restricted?
      	if ( $restricted )
      		$can_create = false;
      
      	return apply_filters( 'bp_user_can_create_groups', $can_create, $restricted );
      }
      
      function bp_group_creation_tabs() {
      	global $bp;
      
      	if ( !is_array( $bp->groups->group_creation_steps ) )
      		return false;
      
      	if ( !$bp->groups->current_create_step )
      		$bp->groups->current_create_step = array_shift( array_keys( $bp->groups->group_creation_steps ) );
      

Comments are closed.