Changeset 52135 for trunk/src/wp-includes/blocks/template-part.php
- Timestamp:
- 11/11/2021 07:41:38 AM (3 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/blocks/template-part.php
r52062 r52135 56 56 $template_part_file_path = get_theme_file_path( '/block-template-parts/' . $attributes['slug'] . '.html' ); 57 57 if ( 0 === validate_file( $attributes['slug'] ) && file_exists( $template_part_file_path ) ) { 58 $content = _inject_theme_attribute_in_block_template_content( file_get_contents( $template_part_file_path ) ); 58 $content = file_get_contents( $template_part_file_path ); 59 $content = is_string( $content ) && '' !== $content 60 ? _inject_theme_attribute_in_block_template_content( $content ) 61 : ''; 59 62 } 60 63 }
Note: See TracChangeset
for help on using the changeset viewer.