WordPress.org

Make WordPress Core

Changeset 25005


Ignore:
Timestamp:
08/07/2013 07:15:57 AM (8 years ago)
Author:
nacin
Message:

SCRIPT_DEBUG is no longer needed when using develop.svn's src/ directory. see #24976.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/script-loader.php

    r24946 r25005  
    5858    $scripts->default_dirs = array('/wp-admin/js/', '/wp-includes/js/');
    5959
    60     $suffix = defined('SCRIPT_DEBUG') && SCRIPT_DEBUG ? '' : '.min';
     60    if ( ! defined( 'SCRIPT_DEBUG' ) )
     61        define( 'SCRIPT_DEBUG', ! file_exists( ABSPATH . WPINC . '/wp-util.min.js' ) );
     62
     63    $suffix = SCRIPT_DEBUG ? '' : '.min';
    6164
    6265    $scripts->add( 'utils', "/wp-includes/js/utils$suffix.js" );
     
    538541    $styles->default_dirs = array('/wp-admin/', '/wp-includes/css/');
    539542
    540     $suffix = defined('SCRIPT_DEBUG') && SCRIPT_DEBUG ? '' : '.min';
     543    if ( ! defined( 'SCRIPT_DEBUG' ) )
     544        define( 'SCRIPT_DEBUG', ! file_exists( ABSPATH . WPINC . '/wp-util.min.js' ) );
     545
     546    $suffix = SCRIPT_DEBUG ? '' : '.min';
    541547
    542548    $rtl_styles = array( 'wp-admin', 'ie', 'media', 'admin-bar', 'customize-controls', 'media-views', 'wp-color-picker' );
Note: See TracChangeset for help on using the changeset viewer.