Code Duplication    Length = 6-6 lines in 2 locations

projects/plugins/jetpack/modules/custom-post-types/nova.php 2 locations

@@ 424-429 (lines=6) @@
421
		$term_order = get_option( 'nova_menu_order', array() );
422
423
		$return = array();
424
		foreach ( $term_order as $term_id ) {
425
			if ( isset( $grouped_by_term["$term_id"] ) ) {
426
				$return = array_merge( $return, $grouped_by_term["$term_id"] );
427
				unset( $grouped_by_term["$term_id"] );
428
			}
429
		}
430
431
		foreach ( $grouped_by_term as $term_id => $posts ) {
432
			$return = array_merge( $return, $posts );
@@ 1062-1067 (lines=6) @@
1059
		$term_order = get_option( 'nova_menu_order', array() );
1060
1061
		$return = array();
1062
		foreach ( $term_order as $term_id ) {
1063
			if ( isset( $terms_by_id["$term_id"] ) ) {
1064
				$return[] = $terms_by_id["$term_id"];
1065
				unset( $terms_by_id["$term_id"] );
1066
			}
1067
		}
1068
1069
		foreach ( $terms_by_id as $term_id => $term ) {
1070
			$return[] = $term;