Make WordPress Core

Ticket #32333: 32333.patch

File 32333.patch, 1.4 KB (added by azaozz, 10 years ago)
  • src/wp-includes/default-constants.php

     
    7171        if ( !defined('WP_CACHE') )
    7272                define('WP_CACHE', false);
    7373
     74        // Add define('SCRIPT_DEBUG', true); to wp-config.php to enable loading of non-minified,
     75        // non-concatenated scripts and stylesheets.
     76        if ( ! defined( 'SCRIPT_DEBUG' ) ) {
     77                if ( ! empty( $GLOBALS['wp_version'] ) ) {
     78                        $develop_src = false !== strpos( $GLOBALS['wp_version'], '-src' );
     79                } else {
     80                        $develop_src = false;
     81                }
     82
     83                define( 'SCRIPT_DEBUG', $develop_src );
     84        }
     85
    7486        /**
    7587         * Private
    7688         */
  • src/wp-settings.php

     
    2929global $wp_version, $wp_db_version, $tinymce_version, $required_php_version, $required_mysql_version;
    3030require( ABSPATH . WPINC . '/version.php' );
    3131
    32 // Set initial default constants including WP_MEMORY_LIMIT, WP_MAX_MEMORY_LIMIT, WP_DEBUG, WP_CONTENT_DIR and WP_CACHE.
     32// Set initial default constants including WP_MEMORY_LIMIT, WP_MAX_MEMORY_LIMIT, WP_DEBUG, SCRIPT_DEBUG, WP_CONTENT_DIR and WP_CACHE.
    3333wp_initial_constants();
    3434
    3535// Check for the required PHP version and for the MySQL extension or a database drop-in.