Make WordPress Core

Ticket #48803: 48803.1.diff

File 48803.1.diff, 1.8 KB (added by ianbelanger, 5 years ago)

refresh patch including author bio removal

  • wp-content/themes/twentytwenty/inc/template-tags.php

     
    338338                                do_action( 'twentytwenty_start_of_post_meta_list', $post_id, $post_meta, $location );
    339339
    340340                                // Author.
    341                                 if ( in_array( 'author', $post_meta, true ) ) {
     341                                if ( post_type_supports( get_post_type( $post_id ), 'author' ) && in_array( 'author', $post_meta, true ) ) {
    342342
    343343                                        $has_meta = true;
    344344                                        ?>
  • wp-content/themes/twentytwenty/template-parts/content-cover.php

     
    146146                // Single bottom post meta.
    147147                twentytwenty_the_post_meta( get_the_ID(), 'single-bottom' );
    148148
    149                 if ( is_single() ) {
     149                if ( post_type_supports( get_post_type( get_the_ID() ), 'author' ) && is_single() ) {
    150150
    151151                        get_template_part( 'template-parts/entry-author-bio' );
    152152
  • wp-content/themes/twentytwenty/template-parts/content.php

     
    5757                // Single bottom post meta.
    5858                twentytwenty_the_post_meta( get_the_ID(), 'single-bottom' );
    5959
    60                 if ( is_single() ) {
     60                if ( post_type_supports( get_post_type( get_the_ID() ), 'author' ) && is_single() ) {
    6161
    6262                        get_template_part( 'template-parts/entry-author-bio' );
    6363