// Leave if we're not in the import section
if ( !defined( 'WP_LOAD_IMPORTERS' ) )
return;
// Load Importer API
require_once( ABSPATH . 'wp-admin/includes/import.php' );
// Load our importers
$importers = apply_filters( 'bbp_importers', array( 'bbpress' ) );
// Loop through included importers
foreach ( $importers as $importer ) {
// Allow custom importer directory
$import_dir = apply_filters( 'bbp_importer_path', $this->admin_dir . 'importers', $importer );
// Compile the importer path
$import_file = trailingslashit( $import_dir ) . $importer . '.php';