Code Duplication    Length = 13-15 lines in 2 locations

class.jetpack.php 1 location

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

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

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