WordPress.org

Make WordPress Core

Ticket #39860: twentyfifteen.diff

File twentyfifteen.diff, 685 bytes (added by sixhours, 3 years ago)

Check for is_wp_error() before outputting get_the_tag_list() in Twenty Fifteen

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

     
    9797                }
    9898
    9999                $tags_list = get_the_tag_list( '', _x( ', ', 'Used between list items, there is a space after the comma.', 'twentyfifteen' ) );
    100                 if ( $tags_list ) {
     100                if ( $tags_list && ! is_wp_error( $tags_list ) ) {
    101101                        printf( '<span class="tags-links"><span class="screen-reader-text">%1$s </span>%2$s</span>',
    102102                                _x( 'Tags', 'Used before tag names.', 'twentyfifteen' ),
    103103                                $tags_list