Code Duplication    Length = 13-15 lines in 2 locations

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

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

class.jetpack.php 1 location

@@ 3984-3998 (lines=15) @@
3981
		return true;
3982
	}
3983
3984
	function jetpack_menu_order( $menu_order ) {
3985
		$jp_menu_order = array();
3986
3987
		foreach ( $menu_order as $index => $item ) {
3988
			if ( $item != 'jetpack' ) {
3989
				$jp_menu_order[] = $item;
3990
			}
3991
3992
			if ( $index == 0 ) {
3993
				$jp_menu_order[] = 'jetpack';
3994
			}
3995
		}
3996
3997
		return $jp_menu_order;
3998
	}
3999
4000
	function admin_banner_styles() {
4001
		$min = ( defined( 'SCRIPT_DEBUG' ) && SCRIPT_DEBUG ) ? '' : '.min';