Code Duplication    Length = 13-15 lines in 2 locations

class.jetpack.php 1 location

@@ 3906-3920 (lines=15) @@
3903
		return true;
3904
	}
3905
3906
	function jetpack_menu_order( $menu_order ) {
3907
		$jp_menu_order = array();
3908
3909
		foreach ( $menu_order as $index => $item ) {
3910
			if ( $item != 'jetpack' ) {
3911
				$jp_menu_order[] = $item;
3912
			}
3913
3914
			if ( $index == 0 ) {
3915
				$jp_menu_order[] = 'jetpack';
3916
			}
3917
		}
3918
3919
		return $jp_menu_order;
3920
	}
3921
3922
	function admin_banner_styles() {
3923
		$min = ( defined( 'SCRIPT_DEBUG' ) && SCRIPT_DEBUG ) ? '' : '.min';

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

@@ 99-111 (lines=13) @@
96
		echo '</noscript>';
97
	}
98
99
	function jetpack_menu_order( $menu_order ) {
100
		$jp_menu_order = array();
101
102
		foreach ( $menu_order as $index => $item ) {
103
			if ( $item != 'jetpack' )
104
				$jp_menu_order[] = $item;
105
106
			if ( $index == 0 )
107
				$jp_menu_order[] = 'jetpack';
108
		}
109
110
		return $jp_menu_order;
111
	}
112
113
	function page_render() {
114
		/** This action is already documented in views/admin/admin-page.php */