Make WordPress Core

Ticket #46420: 46420.diff

File 46420.diff, 938 bytes (added by truchot, 5 years ago)
  • src/wp-includes/general-template.php

    diff --git a/src/wp-includes/general-template.php b/src/wp-includes/general-template.php
    index 0b12a0c123..d34d500e22 100644
    a b function feed_links_extra( $args = array() ) { 
    28862886                }
    28872887        } elseif ( is_tax() ) {
    28882888                $term  = get_queried_object();
    2889                 $tax   = get_taxonomy( $term->taxonomy );
    2890                 $title = sprintf( $args['taxtitle'], get_bloginfo( 'name' ), $args['separator'], $term->name, $tax->labels->singular_name );
    2891                 $href  = get_term_feed_link( $term->term_id, $term->taxonomy );
     2889
     2890                if ( $term ) {
     2891                        $tax   = get_taxonomy( $term->taxonomy );
     2892                        $title = sprintf( $args['taxtitle'], get_bloginfo( 'name' ), $args['separator'], $term->name, $tax->labels->singular_name );
     2893                        $href  = get_term_feed_link( $term->term_id, $term->taxonomy );
     2894                }
    28922895        } elseif ( is_author() ) {
    28932896                $author_id = intval( get_query_var( 'author' ) );
    28942897