diff --git a/src/wp-includes/script-loader.php b/src/wp-includes/script-loader.php
index 972b4497a6..da2374ad76 100644
a
|
b
|
function enqueue_block_styles_assets() { |
2459 | 2459 | if ( wp_should_load_separate_core_block_assets() ) { |
2460 | 2460 | add_filter( |
2461 | 2461 | 'render_block', |
2462 | | function( $html ) use ( $style_properties ) { |
2463 | | wp_enqueue_style( $style_properties['style_handle'] ); |
| 2462 | function( $html, $block ) use ( $block_name, $style_properties ) { |
| 2463 | if( $block['blockName'] === $block_name ){ |
| 2464 | wp_enqueue_style( $style_properties['style_handle'] ); |
| 2465 | } |
2464 | 2466 | return $html; |
2465 | | } |
| 2467 | }, |
| 2468 | 10, |
| 2469 | 2 |
2466 | 2470 | ); |
2467 | 2471 | } else { |
2468 | 2472 | wp_enqueue_style( $style_properties['style_handle'] ); |