Skip to content
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Make sure global styles only load in the front end.
  • Loading branch information
tellthemachines committed Jan 25, 2024
commit bef93115cde2f3e4b5c62d3497a38af98a01e5e7
4 changes: 4 additions & 0 deletions src/wp-includes/script-loader.php
Original file line number Diff line number Diff line change
Expand Up @@ -2478,6 +2478,10 @@ static function ( $node ) {
* @since 5.8.0
*/
function wp_enqueue_global_styles() {
if ( is_admin() ) {
return;
}

$separate_assets = wp_should_load_separate_core_block_assets();
$is_block_theme = wp_is_block_theme();
$is_classic_theme = ! $is_block_theme;
Expand Down