diff --git a/functions.php b/functions.php index 9a333b47e..9c14de24e 100644 --- a/functions.php +++ b/functions.php @@ -501,7 +501,7 @@ if ( ! function_exists( 'twentytwelve_entry_meta' ) ) : $categories_list = get_the_category_list( __( ', ', 'twentytwelve' ) ); /* translators: Used between list items, there is a space after the comma. */ - $tag_list = get_the_tag_list( '', __( ', ', 'twentytwelve' ) ); + $tags_list = get_the_tag_list( '', __( ', ', 'twentytwelve' ) ); $date = sprintf( '', @@ -519,7 +519,7 @@ if ( ! function_exists( 'twentytwelve_entry_meta' ) ) : get_the_author() ); - if ( $tag_list ) { + if ( $tags_list && ! is_wp_error( $tags_list ) ) { /* translators: 1: Category name, 2: Tag name, 3: Date, 4: Author display name. */ $utility_text = __( 'This entry was posted in %1$s and tagged %2$s on %3$s by %4$s.', 'twentytwelve' ); } elseif ( $categories_list ) { @@ -533,7 +533,7 @@ if ( ! function_exists( 'twentytwelve_entry_meta' ) ) : printf( $utility_text, $categories_list, - $tag_list, + $tags_list, $date, $author );