Code Duplication    Length = 13-13 lines in 2 locations

wp-includes/post-template.php 2 locations

@@ 637-649 (lines=13) @@
634
				$classes[] = 'author-' . sanitize_html_class( $author->user_nicename, $author->ID );
635
				$classes[] = 'author-' . $author->ID;
636
			}
637
		} elseif ( is_category() ) {
638
			$cat = $wp_query->get_queried_object();
639
			$classes[] = 'category';
640
			if ( isset( $cat->term_id ) ) {
641
				$cat_class = sanitize_html_class( $cat->slug, $cat->term_id );
642
				if ( is_numeric( $cat_class ) || ! trim( $cat_class, '-' ) ) {
643
					$cat_class = $cat->term_id;
644
				}
645
646
				$classes[] = 'category-' . $cat_class;
647
				$classes[] = 'category-' . $cat->term_id;
648
			}
649
		} elseif ( is_tag() ) {
650
			$tag = $wp_query->get_queried_object();
651
			$classes[] = 'tag';
652
			if ( isset( $tag->term_id ) ) {
@@ 661-673 (lines=13) @@
658
				$classes[] = 'tag-' . $tag_class;
659
				$classes[] = 'tag-' . $tag->term_id;
660
			}
661
		} elseif ( is_tax() ) {
662
			$term = $wp_query->get_queried_object();
663
			if ( isset( $term->term_id ) ) {
664
				$term_class = sanitize_html_class( $term->slug, $term->term_id );
665
				if ( is_numeric( $term_class ) || ! trim( $term_class, '-' ) ) {
666
					$term_class = $term->term_id;
667
				}
668
669
				$classes[] = 'tax-' . sanitize_html_class( $term->taxonomy );
670
				$classes[] = 'term-' . $term_class;
671
				$classes[] = 'term-' . $term->term_id;
672
			}
673
		}
674
	} elseif ( is_page() ) {
675
		$classes[] = 'page';
676