Code Duplication    Length = 13-15 lines in 2 locations

class.jetpack.php 1 location

@@ 3853-3867 (lines=15) @@
3850
		return true;
3851
	}
3852
3853
	function jetpack_menu_order( $menu_order ) {
3854
		$jp_menu_order = array();
3855
3856
		foreach ( $menu_order as $index => $item ) {
3857
			if ( $item != 'jetpack' ) {
3858
				$jp_menu_order[] = $item;
3859
			}
3860
3861
			if ( $index == 0 ) {
3862
				$jp_menu_order[] = 'jetpack';
3863
			}
3864
		}
3865
3866
		return $jp_menu_order;
3867
	}
3868
3869
	function admin_banner_styles() {
3870
		$min = ( defined( 'SCRIPT_DEBUG' ) && SCRIPT_DEBUG ) ? '' : '.min';

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

@@ 76-88 (lines=13) @@
73
		echo '</noscript>';
74
	}
75
76
	function jetpack_menu_order( $menu_order ) {
77
		$jp_menu_order = array();
78
79
		foreach ( $menu_order as $index => $item ) {
80
			if ( $item != 'jetpack' )
81
				$jp_menu_order[] = $item;
82
83
			if ( $index == 0 )
84
				$jp_menu_order[] = 'jetpack';
85
		}
86
87
		return $jp_menu_order;
88
	}
89
90
	function page_render() {
91
		/** This action is already documented in views/admin/admin-page.php */