wp/wp-includes/widgets/class-wp-widget-recent-comments.php
changeset 19 3d72ae0968f4
parent 18 be944660c56a
equal deleted inserted replaced
18:be944660c56a 19:3d72ae0968f4
   132 
   132 
   133 		if ( 'html5' === $format ) {
   133 		if ( 'html5' === $format ) {
   134 			// The title may be filtered: Strip out HTML and make sure the aria-label is never empty.
   134 			// The title may be filtered: Strip out HTML and make sure the aria-label is never empty.
   135 			$title      = trim( strip_tags( $title ) );
   135 			$title      = trim( strip_tags( $title ) );
   136 			$aria_label = $title ? $title : $default_title;
   136 			$aria_label = $title ? $title : $default_title;
   137 			$output    .= '<nav role="navigation" aria-label="' . esc_attr( $aria_label ) . '">';
   137 			$output    .= '<nav aria-label="' . esc_attr( $aria_label ) . '">';
   138 		}
   138 		}
   139 
   139 
   140 		$output .= '<ul id="' . esc_attr( $recent_comments_id ) . '">';
   140 		$output .= '<ul id="' . esc_attr( $recent_comments_id ) . '">';
   141 		if ( is_array( $comments ) && $comments ) {
   141 		if ( is_array( $comments ) && $comments ) {
   142 			// Prime cache for associated posts. (Prime post term cache if we need it for permalinks.)
   142 			// Prime cache for associated posts. (Prime post term cache if we need it for permalinks.)