Code Duplication    Length = 15-15 lines in 2 locations

class.jetpack.php 2 locations

@@ 4693-4707 (lines=15) @@
4690
					wp_safe_redirect( admin_url() . 'plugins.php?deactivate=true&plugin_status=all&paged=1&s=' );
4691
				}
4692
				break;
4693
			case 'jetpack-manage-opt-out':
4694
4695
				if ( check_admin_referer( 'jetpack_manage_banner_opt_out' ) ) {
4696
					// Don't show the banner again
4697
4698
					Jetpack_Options::update_option( 'dismissed_manage_banner', true );
4699
					// redirect back to the page that had the notice
4700
					if ( wp_get_referer() ) {
4701
						wp_safe_redirect( wp_get_referer() );
4702
					} else {
4703
						// Take me to Jetpack
4704
						wp_safe_redirect( admin_url( 'admin.php?page=jetpack' ) );
4705
					}
4706
				}
4707
				break;
4708
			case 'jetpack-protect-multisite-opt-out':
4709
4710
				if ( check_admin_referer( 'jetpack_protect_multisite_banner_opt_out' ) ) {
@@ 4708-4722 (lines=15) @@
4705
					}
4706
				}
4707
				break;
4708
			case 'jetpack-protect-multisite-opt-out':
4709
4710
				if ( check_admin_referer( 'jetpack_protect_multisite_banner_opt_out' ) ) {
4711
					// Don't show the banner again
4712
4713
					update_site_option( 'jetpack_dismissed_protect_multisite_banner', true );
4714
					// redirect back to the page that had the notice
4715
					if ( wp_get_referer() ) {
4716
						wp_safe_redirect( wp_get_referer() );
4717
					} else {
4718
						// Take me to Jetpack
4719
						wp_safe_redirect( admin_url( 'admin.php?page=jetpack' ) );
4720
					}
4721
				}
4722
				break;
4723
			case 'jetpack-manage-opt-in':
4724
				if ( check_admin_referer( 'jetpack_manage_banner_opt_in' ) ) {
4725
					// This makes sure that we are redirect to jetpack home so that we can see the Success Message.