diff --git a/wp-includes/script-loader.php b/wp-includes/script-loader.php index 1e814a324f..b31c0b1700 100644 --- a/wp-includes/script-loader.php +++ b/wp-includes/script-loader.php @@ -2252,7 +2252,7 @@ function script_concat_settings() { function wp_common_block_scripts_and_styles() { global $current_screen; - if ( is_admin() && ! $current_screen->is_block_editor() ) { + if ( ( $current_screen instanceof WP_Screen ) && ! $current_screen->is_block_editor() ) { return; } @@ -2286,7 +2286,7 @@ function wp_common_block_scripts_and_styles() { function wp_enqueue_registered_block_scripts_and_styles() { global $current_screen; - $is_editor = ( is_admin() && $current_screen->is_block_editor() ); + $is_editor = ( ( $current_screen instanceof WP_Screen ) && $current_screen->is_block_editor() ); $block_registry = WP_Block_Type_Registry::get_instance(); foreach ( $block_registry->get_all_registered() as $block_name => $block_type ) { diff --git a/wp-includes/version.php b/wp-includes/version.php index 464f6d4d7a..9d3ad6234b 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -4,7 +4,7 @@ * * @global string $wp_version */ -$wp_version = '5.0-beta3-43892'; +$wp_version = '5.0-beta3-43893'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.