Skip to:
Content

bbPress.org

Changeset 5286


Ignore:
Timestamp:
02/11/2014 07:35:47 PM (10 years ago)
Author:
johnjamesjacoby
Message:

Smarter build/src toggling for the stub plugin. See #2542.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/bbpress.php

    r5271 r5286  
    2626if ( !defined( 'ABSPATH' ) ) exit;
    2727
     28// Assume you want to load from build
     29$bbp_loader = __DIR__ . '/build/bbpress.php';
     30
     31// Load from source if no build exists
     32if ( ! file_exists( $bbp_loader ) || defined( 'BBP_LOAD_SOURCE' ) ) {
     33    $bbp_loader = __DIR__ . '/src/bbpress.php';
     34}
     35
    2836// Include bbPress
    29 include( __DIR__ . '/src/bbpress.php' );
     37include( $bbp_loader );
     38
     39// Unset the loader, since it's loaded in global scope
     40unset( $bbp_loader );
Note: See TracChangeset for help on using the changeset viewer.