Code Duplication    Length = 13-15 lines in 2 locations

_inc/lib/admin-pages/class.jetpack-react-page.php 1 location

@@ 84-96 (lines=13) @@
81
		echo '</noscript>';
82
	}
83
84
	function jetpack_menu_order( $menu_order ) {
85
		$jp_menu_order = array();
86
87
		foreach ( $menu_order as $index => $item ) {
88
			if ( $item != 'jetpack' )
89
				$jp_menu_order[] = $item;
90
91
			if ( $index == 0 )
92
				$jp_menu_order[] = 'jetpack';
93
		}
94
95
		return $jp_menu_order;
96
	}
97
98
	function page_render() {
99
		/** This action is already documented in views/admin/admin-page.php */

class.jetpack.php 1 location

@@ 3828-3842 (lines=15) @@
3825
		return true;
3826
	}
3827
3828
	function jetpack_menu_order( $menu_order ) {
3829
		$jp_menu_order = array();
3830
3831
		foreach ( $menu_order as $index => $item ) {
3832
			if ( $item != 'jetpack' ) {
3833
				$jp_menu_order[] = $item;
3834
			}
3835
3836
			if ( $index == 0 ) {
3837
				$jp_menu_order[] = 'jetpack';
3838
			}
3839
		}
3840
3841
		return $jp_menu_order;
3842
	}
3843
3844
	function admin_banner_styles() {
3845
		$min = ( defined( 'SCRIPT_DEBUG' ) && SCRIPT_DEBUG ) ? '' : '.min';