Code Duplication    Length = 13-15 lines in 2 locations

class.jetpack.php 1 location

@@ 3899-3913 (lines=15) @@
3896
		return true;
3897
	}
3898
3899
	function jetpack_menu_order( $menu_order ) {
3900
		$jp_menu_order = array();
3901
3902
		foreach ( $menu_order as $index => $item ) {
3903
			if ( $item != 'jetpack' ) {
3904
				$jp_menu_order[] = $item;
3905
			}
3906
3907
			if ( $index == 0 ) {
3908
				$jp_menu_order[] = 'jetpack';
3909
			}
3910
		}
3911
3912
		return $jp_menu_order;
3913
	}
3914
3915
	function admin_banner_styles() {
3916
		$min = ( defined( 'SCRIPT_DEBUG' ) && SCRIPT_DEBUG ) ? '' : '.min';

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

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