Making WordPress.org

Changeset 2914


Ignore:
Timestamp:
04/07/2016 03:23:49 PM (8 years ago)
Author:
iandunn
Message:

WordCamp Site Cloner: Include WordCamp_Loader before trying to access it.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/wordcamp.org/public_html/wp-content/plugins/wordcamp-site-cloner/wordcamp-site-cloner.php

    r2898 r2914  
    1414*/
    1515
     16// todo if Jetpack_Custom_CSS:get_css is callable, register these, otherwise fatal errors
    1617add_action( 'plugins_loaded',        __NAMESPACE__ . '\get_wordcamp_sites' );
    1718add_action( 'admin_enqueue_scripts', __NAMESPACE__ . '\register_scripts' );
     
    104105 */
    105106function get_wordcamp_sites() {
     107    require_once( WP_PLUGIN_DIR . '/wcpt/wcpt-wordcamp/wordcamp-loader.php' );
     108
    106109    // plugins_loaded is runs on every screen, but we only need this when loading the Customizer and Previewer
    107110    if ( 'customize.php' != basename( $_SERVER['SCRIPT_NAME'] ) && empty( $_REQUEST['wp_customize'] ) ) {
     
    120123    $wordcamps = get_posts( array(
    121124        'post_type'      => 'wordcamp',
    122         'post_status'    => WordCamp_Loader::get_public_post_statuses(),
     125        'post_status'    => \WordCamp_Loader::get_public_post_statuses(),
    123126        'posts_per_page' => 125, // todo temporary workaround until able to add filters to make hundreds of sites manageable
    124127        'meta_key'       => 'Start Date (YYYY-mm-dd)',
Note: See TracChangeset for help on using the changeset viewer.