WordPress.org

Make WordPress Core

Ticket #17749: new-unit-tests.diff

File new-unit-tests.diff, 2.2 KB (added by nbachiyski, 3 years ago)
  • wp-includes/media.php

     
    12881288                return apply_filters( 'embed_maybe_make_link', $output, $url ); 
    12891289        } 
    12901290} 
    1291 $wp_embed = new WP_Embed(); 
     1291$GLOBALS['wp_embed'] = new WP_Embed(); 
    12921292 
    12931293/** 
    12941294 * Register an embed handler. This function should probably only be used for sites that do not support oEmbed. 
  • wp-includes/widgets.php

     
    385385/** 
    386386 * Private 
    387387 */ 
    388  $_wp_deprecated_widgets_callbacks = array( 
     388 $GLOBALS['_wp_deprecated_widgets_callbacks'] = array( 
    389389        'wp_widget_pages', 
    390390        'wp_widget_pages_control', 
    391391        'wp_widget_calendar', 
  • wp-settings.php

     
    100100// Run the installer if WordPress is not installed. 
    101101wp_not_installed(); 
    102102 
     103 
    103104// Load most of WordPress. 
    104105require( ABSPATH . WPINC . '/class-wp-walker.php' ); 
    105106require( ABSPATH . WPINC . '/class-wp-ajax-response.php' ); 
     
    245246 * @global object $wp_widget_factory 
    246247 * @since 2.8.0 
    247248 */ 
    248 $wp_widget_factory = new WP_Widget_Factory(); 
     249$GLOBALS['wp_widget_factory'] = new WP_Widget_Factory(); 
    249250 
    250251do_action( 'setup_theme' ); 
    251252 
  • wp-admin/includes/upgrade.php

     
    13821382                $queries = explode( ';', $queries ); 
    13831383                if ('' == $queries[count($queries) - 1]) array_pop($queries); 
    13841384        } 
     1385        $queries = apply_filters( 'dbdelta_queries', $queries ); 
    13851386 
    13861387        $cqueries = array(); // Creation Queries 
    13871388        $iqueries = array(); // Insertion Queries 
     
    14021403                        // Unrecognized query type 
    14031404                } 
    14041405        } 
     1406        $cqueries = apply_filters( 'dbdelta_create_queries', $cqueries ); 
     1407        $iqueries = apply_filters( 'dbdelta_insert_queries', $iqueries ); 
    14051408 
    14061409        // Check to see which tables and fields exist 
    14071410        if ($tables = $wpdb->get_col('SHOW TABLES;')) {