mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2025-10-16 12:05:38 +00:00
Script Loader: Don't parse $src if the current color scheme isn't registered.
Avoids a `parse_url()` call on each request if the default colors scheme is in use. Fixes #35882. git-svn-id: https://develop.svn.wordpress.org/trunk@36591 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
066f081ed5
commit
3748ec5249
@ -871,13 +871,13 @@ function wp_style_loader_src( $src, $handle ) {
|
||||
$color = 'fresh';
|
||||
|
||||
$color = $_wp_admin_css_colors[$color];
|
||||
$parsed = parse_url( $src );
|
||||
$url = $color->url;
|
||||
|
||||
if ( ! $url ) {
|
||||
return false;
|
||||
}
|
||||
|
||||
$parsed = parse_url( $src );
|
||||
if ( isset($parsed['query']) && $parsed['query'] ) {
|
||||
wp_parse_str( $parsed['query'], $qv );
|
||||
$url = add_query_arg( $qv, $url );
|
||||
|
||||
Loading…
Reference in New Issue
Block a user