diff --git a/wp-includes/block-template.php b/wp-includes/block-template.php index de266c04f2..7bea75dca4 100644 --- a/wp-includes/block-template.php +++ b/wp-includes/block-template.php @@ -48,6 +48,10 @@ function _add_template_loader_filters() { function locate_block_template( $template, $type, array $templates ) { global $_wp_current_template_content; + if ( ! current_theme_supports( 'block-templates' ) ) { + return $template; + } + if ( $template ) { /* * locate_template() has found a PHP template at the path specified by $template. diff --git a/wp-includes/version.php b/wp-includes/version.php index 0351f05a50..9ea4ae884f 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -16,7 +16,7 @@ * * @global string $wp_version */ -$wp_version = '6.0-alpha-52696'; +$wp_version = '6.0-alpha-52697'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.