Skip to:
Content

BuddyPress.org


Ignore:
Timestamp:
11/22/2015 04:58:34 AM (9 years ago)
Author:
tw2113
Message:

More docs cleanup for BP-Groups component.

See #6401.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/bp-groups/bp-groups-adminbar.php

    r10148 r10373  
    2626    $bp = buddypress();
    2727
    28     // Only show if viewing a group
     28    // Only show if viewing a group.
    2929    if ( ! bp_is_group() || bp_is_group_create() ) {
    3030        return false;
    3131    }
    3232
    33     // Only show this menu to group admins and super admins
     33    // Only show this menu to group admins and super admins.
    3434    if ( ! bp_current_user_can( 'bp_moderate' ) && ! bp_group_is_admin() ) {
    3535        return false;
    3636    }
    3737
    38     // Unique ID for the 'Edit Group' menu
     38    // Unique ID for the 'Edit Group' menu.
    3939    $bp->group_admin_menu_id = 'group-admin';
    4040
    41     // Add the top-level Group Admin button
     41    // Add the top-level Group Admin button.
    4242    $wp_admin_bar->add_menu( array(
    4343        'id'    => $bp->group_admin_menu_id,
     
    4646    ) );
    4747
    48     // Index of the Manage tabs parent slug
     48    // Index of the Manage tabs parent slug.
    4949    $nav_index = $bp->groups->current_group->slug . '_manage';
    5050
    51     // Check if current group has Manage tabs
     51    // Check if current group has Manage tabs.
    5252    if ( empty( $bp->bp_options_nav[ $nav_index ] ) ) {
    5353        return;
    5454    }
    5555
    56     // Build the Group Admin menus
     56    // Build the Group Admin menus.
    5757    foreach ( $bp->bp_options_nav[ $nav_index ] as $menu ) {
    5858        /**
     
    6666            $title = sprintf( _x( 'Edit Group %s', 'Group WP Admin Bar manage links', 'buddypress' ), $menu['name'] );
    6767
    68             // Title is specific for delete
     68            // Title is specific for delete.
    6969            if ( 'delete-group' == $menu['slug'] ) {
    7070                $title = sprintf( _x( '%s Group', 'Group WP Admin Bar delete link', 'buddypress' ), $menu['name'] );
Note: See TracChangeset for help on using the changeset viewer.