mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-05-25 21:54:28 +00:00
Twenty Ten: Use correct path for loading block patterns.
By using `get_template_directory()` instead of `get_stylesheet_directory()`, we make sure to include the `block-patterns.php` file from the parent theme. This avoids a PHP fatal error when using a child theme of Twenty Ten. Follow-up to [51106]. Props ryelle, sabernhardt, loranrendel. Fixes #53752. git-svn-id: https://develop.svn.wordpress.org/trunk@51482 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -740,7 +740,7 @@ function twentyten_block_editor_styles() {
|
||||
add_action( 'enqueue_block_editor_assets', 'twentyten_block_editor_styles' );
|
||||
|
||||
// Block Patterns.
|
||||
require get_stylesheet_directory() . '/block-patterns.php';
|
||||
require get_template_directory() . '/block-patterns.php';
|
||||
|
||||
if ( ! function_exists( 'wp_body_open' ) ) :
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user