Skip to:
Content

BuddyPress.org

Changeset 5366


Ignore:
Timestamp:
11/24/2011 04:37:47 AM (13 years ago)
Author:
boonebgorges
Message:

Deprecates bp_has_custom_activation_page() in favor of checking bp_pages for an activation page. Retools bp_get_activation_page() so that it returns the proper network registration page when adding users from a non-root Dashboard. Fixes #2350

Location:
trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/bp-core/deprecated/1.6.php

    r5328 r5366  
    6161    _deprecated_function( __FUNCTION__, '1.6', 'No longer used' );
    6262}
     63
     64/**
     65 * Members functions
     66 */
     67
     68/**
     69 * @deprecated 1.6
     70 * @deprecated No longer used. Check for $bp->pages->activate->slug instead.
     71 */
     72function bp_has_custom_activation_page() {
     73    _deprecated_function( __FUNCTION__, '1.6' );
     74}
     75
    6376?>
  • trunk/bp-members/bp-members-template.php

    r5302 r5366  
    978978    }
    979979
    980 function bp_has_custom_activation_page() {
    981     if ( locate_template( array( 'activate.php' ), false ) || locate_template( array( '/registration/activate.php' ), false ) )
    982         return true;
    983 
    984     return false;
    985 }
    986 
    987980function bp_activation_page() {
    988981    echo bp_get_activation_page();
     
    991984        global $bp;
    992985
    993         if ( bp_has_custom_activation_page() )
     986        // Check the global directly to make sure the WP page exists in $bp->pages
     987        if ( !empty( $bp->pages->activate->slug ) )
    994988            $page = trailingslashit( bp_get_root_domain() . '/' . $bp->pages->activate->slug );
    995989        else
Note: See TracChangeset for help on using the changeset viewer.