Changeset 52610 for trunk/src/wp-includes/block-template.php
- Timestamp:
- 01/20/2022 11:51:22 PM (4 years ago)
- File:
-
- 1 edited
-
trunk/src/wp-includes/block-template.php (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/block-template.php
r52597 r52610 161 161 $parent_theme_base_path = get_template_directory() . DIRECTORY_SEPARATOR; 162 162 163 // Is the currenttheme a child theme, and is the PHP fallback template part of it?163 // Is the active theme a child theme, and is the PHP fallback template part of it? 164 164 if ( 165 165 strpos( $fallback_template, $theme_base_path ) === 0 && … … 181 181 ) { 182 182 // Unfortunately, we cannot trust $templates[0]->theme, since it will always 183 // be set to the currenttheme's slug by _build_block_template_result_from_file(),184 // even if the block template is really coming from the currenttheme's parent.185 // (The reason for this is that we want it to be associated with the currenttheme183 // be set to the active theme's slug by _build_block_template_result_from_file(), 184 // even if the block template is really coming from the active theme's parent. 185 // (The reason for this is that we want it to be associated with the active theme 186 186 // -- not its parent -- once we edit it and store it to the DB as a wp_template CPT.) 187 187 // Instead, we use _get_block_template_file() to locate the block template file.
Note: See TracChangeset
for help on using the changeset viewer.