Skip to content

Commit

Permalink
WordPress.com Features: Don't load admin color schemes if Jetpack is …
Browse files Browse the repository at this point in the history
…not active (#37233)

* Jetpack Mu Wpcom: Register the admin color schemes only when Jetpack is active

* changelog
  • Loading branch information
arthur791004 authored and pkuliga committed May 9, 2024
1 parent 1d97290 commit 80bb8ed
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
Significance: patch
Type: fixed

WordPress.com Features: Don't load admin color schemes if Jetpack is not active
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,7 @@ function enqueue_color_scheme_for_sidebar_notice() {
}
}

if ( function_exists( 'wpcom_is_nav_redesign_enabled' ) && wpcom_is_nav_redesign_enabled() ) {
if ( defined( 'JETPACK__PLUGIN_FILE' ) && function_exists( 'wpcom_is_nav_redesign_enabled' ) && wpcom_is_nav_redesign_enabled() ) {
add_action( 'admin_init', 'register_calypso_admin_color_schemes' );
add_action( 'admin_enqueue_scripts', 'enqueue_color_scheme_for_sidebar_notice' );
add_filter( 'css_do_concat', 'disable_css_concat_for_color_schemes', 10, 2 );
Expand Down

0 comments on commit 80bb8ed

Please sign in to comment.