Twenty Seventeen: Avoid an undefined index notice after [39291].
props westonruter. see #38847. Built from https://develop.svn.wordpress.org/trunk@39317 git-svn-id: http://core.svn.wordpress.org/trunk@39257 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
1c110b8474
commit
7ba9399fbd
|
@ -435,9 +435,12 @@ add_filter( 'wp_calculate_image_sizes', 'twentyseventeen_content_image_sizes_att
|
|||
* @return string The filtered header image HTML.
|
||||
*/
|
||||
function twentyseventeen_header_image_tag( $html, $header, $attr ) {
|
||||
return str_replace( $attr['sizes'], '100vw', $html );
|
||||
if ( isset( $attr['sizes'] ) ) {
|
||||
$html = str_replace( $attr['sizes'], '100vw', $html );
|
||||
}
|
||||
return $html;
|
||||
}
|
||||
add_filter ( 'get_header_image_tag', 'twentyseventeen_header_image_tag', 10, 3 );
|
||||
add_filter( 'get_header_image_tag', 'twentyseventeen_header_image_tag', 10, 3 );
|
||||
|
||||
/**
|
||||
* Add custom image sizes attribute to enhance responsive image functionality
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
*
|
||||
* @global string $wp_version
|
||||
*/
|
||||
$wp_version = '4.7-beta4-39316';
|
||||
$wp_version = '4.7-beta4-39317';
|
||||
|
||||
/**
|
||||
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
||||
|
|
Loading…
Reference in New Issue