Skip to:
Content

BuddyPress.org


Ignore:
Timestamp:
01/24/2014 11:48:48 PM (10 years ago)
Author:
johnjamesjacoby
Message:

Replace BP_PLUGIN_DIR and BP_PLUGIN_URL constant usages with plugin_dir and plugin_url BuddyPress variables, respectively. Also replaces $bp global touches with buddypress() calls within the above scopes.

File:
1 edited

Legend:

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

    r7521 r7756  
    2222     * @uses BP_Core::bootstrap()
    2323     */
    24     function __construct() {
     24    public function __construct() {
    2525        parent::start(
    2626            'core',
    27             __( 'BuddyPress Core', 'buddypress' )
    28             , BP_PLUGIN_DIR
     27            __( 'BuddyPress Core', 'buddypress' ),
     28            buddypress()->plugin_dir
    2929        );
    3030
     
    9696
    9797        // Loop through optional components
    98         foreach( $bp->optional_components as $component )
    99             if ( bp_is_active( $component ) && file_exists( BP_PLUGIN_DIR . '/bp-' . $component . '/bp-' . $component . '-loader.php' ) )
    100                 include( BP_PLUGIN_DIR . '/bp-' . $component . '/bp-' . $component . '-loader.php' );
     98        foreach( $bp->optional_components as $component ) {
     99            if ( bp_is_active( $component ) && file_exists( $bp->plugin_dir . '/bp-' . $component . '/bp-' . $component . '-loader.php' ) ) {
     100                include( $bp->plugin_dir . '/bp-' . $component . '/bp-' . $component . '-loader.php' );
     101            }
     102        }
    101103
    102104        // Loop through required components
    103         foreach( $bp->required_components as $component )
    104             if ( file_exists( BP_PLUGIN_DIR . '/bp-' . $component . '/bp-' . $component . '-loader.php' ) )
    105                 include( BP_PLUGIN_DIR . '/bp-' . $component . '/bp-' . $component . '-loader.php' );
     105        foreach( $bp->required_components as $component ) {
     106            if ( file_exists( $bp->plugin_dir . '/bp-' . $component . '/bp-' . $component . '-loader.php' ) ) {
     107                include( $bp->plugin_dir . '/bp-' . $component . '/bp-' . $component . '-loader.php' );
     108            }
     109        }
    106110
    107111        // Add Core to required components
Note: See TracChangeset for help on using the changeset viewer.