WordPress.org

Make WordPress Core

Changeset 25465


Ignore:
Timestamp:
09/16/13 22:11:12 (7 months ago)
Author:
nacin
Message:

If the script_loader_src filter returns nothing, bail instead of printing <script src="">.

props niallkennedy.
fixes #22470.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/class.wp-scripts.php

    r24635 r25465  
    120120        $src = esc_url( apply_filters( 'script_loader_src', $src, $handle ) ); 
    121121 
     122        if ( ! $src ) 
     123            return true; 
     124 
    122125        if ( $this->do_concat ) 
    123126            $this->print_html .= "<script type='text/javascript' src='$src'></script>\n"; 
Note: See TracChangeset for help on using the changeset viewer.