Code Duplication    Length = 15-15 lines in 2 locations

class.jetpack.php 2 locations

@@ 4541-4555 (lines=15) @@
4538
					wp_safe_redirect( admin_url() . 'plugins.php?deactivate=true&plugin_status=all&paged=1&s=' );
4539
				}
4540
				break;
4541
			case 'jetpack-manage-opt-out':
4542
4543
				if ( check_admin_referer( 'jetpack_manage_banner_opt_out' ) ) {
4544
					// Don't show the banner again
4545
4546
					Jetpack_Options::update_option( 'dismissed_manage_banner', true );
4547
					// redirect back to the page that had the notice
4548
					if ( wp_get_referer() ) {
4549
						wp_safe_redirect( wp_get_referer() );
4550
					} else {
4551
						// Take me to Jetpack
4552
						wp_safe_redirect( admin_url( 'admin.php?page=jetpack' ) );
4553
					}
4554
				}
4555
				break;
4556
			case 'jetpack-protect-multisite-opt-out':
4557
4558
				if ( check_admin_referer( 'jetpack_protect_multisite_banner_opt_out' ) ) {
@@ 4556-4570 (lines=15) @@
4553
					}
4554
				}
4555
				break;
4556
			case 'jetpack-protect-multisite-opt-out':
4557
4558
				if ( check_admin_referer( 'jetpack_protect_multisite_banner_opt_out' ) ) {
4559
					// Don't show the banner again
4560
4561
					update_site_option( 'jetpack_dismissed_protect_multisite_banner', true );
4562
					// redirect back to the page that had the notice
4563
					if ( wp_get_referer() ) {
4564
						wp_safe_redirect( wp_get_referer() );
4565
					} else {
4566
						// Take me to Jetpack
4567
						wp_safe_redirect( admin_url( 'admin.php?page=jetpack' ) );
4568
					}
4569
				}
4570
				break;
4571
			case 'jetpack-manage-opt-in':
4572
				if ( check_admin_referer( 'jetpack_manage_banner_opt_in' ) ) {
4573
					// This makes sure that we are redirect to jetpack home so that we can see the Success Message.