Skip to:
Content

BuddyPress.org

Ticket #8609: 8609.patch

File 8609.patch, 2.3 KB (added by imath, 5 years ago)
  • src/bp-groups/classes/class-bp-groups-component.php

    diff --git src/bp-groups/classes/class-bp-groups-component.php src/bp-groups/classes/class-bp-groups-component.php
    index 1e375f825..2eb295658 100644
    class BP_Groups_Component extends BP_Component {  
    364364                        return;
    365365                }
    366366
    367                 /**
    368                  * Filters the preconfigured groups creation steps.
    369                  *
    370                  * @since 1.1.0
    371                  *
    372                  * @param array $value Array of preconfigured group creation steps.
    373                  */
    374                 $this->group_creation_steps = apply_filters( 'groups_create_group_steps', array(
     367                // Set default creation steps.
     368                $group_creation_steps = array(
    375369                        'group-details'  => array(
    376370                                'name'       => _x( 'Details', 'Group screen nav', 'buddypress' ),
    377371                                'position'   => 0
    class BP_Groups_Component extends BP_Component {  
    380374                                'name'       => _x( 'Settings', 'Group screen nav', 'buddypress' ),
    381375                                'position'   => 10
    382376                        )
    383                 ) );
     377                );
    384378
    385379                // If avatar uploads are not disabled, add avatar option.
    386380                $disabled_avatar_uploads = (int) bp_disable_group_avatar_uploads();
    387381                if ( ! $disabled_avatar_uploads && $bp->avatar->show_avatars ) {
    388                         $this->group_creation_steps['group-avatar'] = array(
     382                        $group_creation_steps['group-avatar'] = array(
    389383                                'name'     => _x( 'Photo', 'Group screen nav', 'buddypress' ),
    390384                                'position' => 20
    391385                        );
    392386                }
    393387
    394388                if ( bp_group_use_cover_image_header() ) {
    395                         $this->group_creation_steps['group-cover-image'] = array(
     389                        $group_creation_steps['group-cover-image'] = array(
    396390                                'name'     => _x( 'Cover Image', 'Group screen nav', 'buddypress' ),
    397391                                'position' => 25
    398392                        );
    class BP_Groups_Component extends BP_Component {  
    400394
    401395                // If invitations are enabled, add invitations.
    402396                if ( bp_is_active( 'groups', 'invitations' ) ) {
    403                         $this->group_creation_steps['group-invites'] = array(
     397                        $group_creation_steps['group-invites'] = array(
    404398                                'name'     => _x( 'Invites',  'Group screen nav', 'buddypress' ),
    405399                                'position' => 30
    406400                        );
    407401                }
    408402
     403                /**
     404                 * Filters the preconfigured groups creation steps.
     405                 *
     406                 * @since 1.1.0
     407                 *
     408                 * @param array $value Array of preconfigured group creation steps.
     409                 */
     410                $this->group_creation_steps = apply_filters( 'groups_create_group_steps', $group_creation_steps );
     411
    409412                /**
    410413                 * Filters the list of valid groups statuses.
    411414                 *