Skip to:
Content

BuddyPress.org


Ignore:
Timestamp:
11/08/2011 12:11:29 AM (14 years ago)
Author:
johnjamesjacoby
Message:

Attach component creation to 'bp_setup_component' action. Clean up bp-core-hooks.php and include new 'bp_setup_component' hook. Fixes issue with $bp reference in global scope in each component. See #3738.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/bp-core/bp-core-loader.php

    r5272 r5300  
    230230}
    231231
    232 // Initialize the BuddyPress Core
    233 $bp->core = new BP_Core();
     232function bp_setup_core() {
     233    global $bp;
     234    $bp->core = new BP_Core();
     235}
     236add_action( 'bp_setup_components', 'bp_setup_core', 2 );
    234237
    235238?>
Note: See TracChangeset for help on using the changeset viewer.