Code Duplication    Length = 11-11 lines in 2 locations

modules/masterbar/masterbar.php 2 locations

@@ 595-605 (lines=11) @@
592
		}
593
594
		// Stats
595
		if ( Jetpack::is_module_active( 'stats' ) ) {
596
			$wp_admin_bar->add_menu( array(
597
				'parent' => 'blog',
598
				'id'     => 'blog-stats',
599
				'title'  => esc_html__( 'Stats', 'jetpack' ),
600
				'href'   => 'https://wordpress.com/stats/' . esc_attr( $this->primary_site_slug ),
601
				'meta'   => array(
602
					'class' => 'mb-icon',
603
				),
604
			) );
605
		}
606
607
		// Add Calypso plans link and plan type indicator
608
		if ( is_user_member_of_blog( $current_user->ID ) ) {
@@ 865-875 (lines=11) @@
862
				),
863
			) );
864
865
			if ( Jetpack::is_module_active( 'publicize' ) || Jetpack::is_module_active( 'sharedaddy' ) ) {
866
				$wp_admin_bar->add_menu( array(
867
					'parent' => 'configuration',
868
					'id'     => 'sharing',
869
					'title'  => esc_html__( 'Sharing', 'jetpack' ),
870
					'href'   => 'https://wordpress.com/sharing/' . esc_attr( $this->primary_site_slug ),
871
					'meta'   => array(
872
						'class' => 'mb-icon',
873
					),
874
				) );
875
			}
876
877
			$people_title = $this->create_menu_item_pair(
878
				array(