Skip to:
Content

BuddyPress.org

Changeset 2471 for trunk/bp-groups.php


Ignore:
Timestamp:
01/28/2010 06:01:42 PM (15 years ago)
Author:
apeatling
Message:

Merged activity delete functions for better usability. Fixed some issues with the group extension API and plugin compatibility in 1.2

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/bp-groups.php

    r2465 r2471  
    107107
    108108function groups_check_installed() {
    109     global $wpdb, $bp;
    110 
    111109    /* Need to check db tables exist, activate hook no-worky in mu-plugins folder. */
    112110    if ( get_site_option('bp-groups-db-version') < BP_GROUPS_DB_VERSION )
     
    116114
    117115function groups_setup_nav() {
    118     global $bp, $current_blog, $group_obj;
     116    global $bp;
    119117
    120118    if ( $group_id = BP_Groups_Group::group_exists($bp->current_action) ) {
     
    139137        /* Should this group be visible to the logged in user? */
    140138        $bp->groups->current_group->is_group_visible_to_member = ( 'public' == $bp->groups->current_group->status || $is_member ) ? true : false;
    141 
    142         /* Pre 1.1 backwards compatibility - use $bp->groups->current_group instead */
    143         $group_obj = &$bp->groups->current_group;
    144139    }
    145140
     
    667662    global $bp;
    668663
    669     if ( !$bp->is_single_item || $bp->current_component != $bp->groups->slug || $bp->current_action != $bp->activity->slug )
    670         return false;
     664    if ( $bp->current_component != $bp->groups->slug || $bp->current_action != $bp->activity->slug || empty( $bp->action_variables[0] ) )
     665        return false;
     666
     667    $bp->is_single_item = true;
    671668
    672669    bp_core_load_template( apply_filters( 'groups_template_group_home', 'groups/single/home' ) );
     
    12441241        return false;
    12451242
    1246     foreach ( $bp->groups->group_creation_steps as $slug => $step )
     1243    foreach ( $bp->groups->group_creation_steps as $slug => $step ) {
     1244        while ( !empty( $temp[$step['position']] ) )
     1245            $step['position']++;
     1246
    12471247        $temp[$step['position']] = array( 'name' => $step['name'], 'slug' => $slug );
     1248    }
    12481249
    12491250    /* Sort the steps by their position key */
Note: See TracChangeset for help on using the changeset viewer.