Code Duplication    Length = 15-15 lines in 2 locations

class.jetpack.php 2 locations

@@ 4249-4263 (lines=15) @@
4246
					wp_safe_redirect( admin_url() . 'plugins.php?deactivate=true&plugin_status=all&paged=1&s=' );
4247
				}
4248
				break;
4249
			case 'jetpack-manage-opt-out':
4250
4251
				if ( check_admin_referer( 'jetpack_manage_banner_opt_out' ) ) {
4252
					// Don't show the banner again
4253
4254
					Jetpack_Options::update_option( 'dismissed_manage_banner', true );
4255
					// redirect back to the page that had the notice
4256
					if ( wp_get_referer() ) {
4257
						wp_safe_redirect( wp_get_referer() );
4258
					} else {
4259
						// Take me to Jetpack
4260
						wp_safe_redirect( admin_url( 'admin.php?page=jetpack' ) );
4261
					}
4262
				}
4263
				break;
4264
			case 'jetpack-protect-multisite-opt-out':
4265
4266
				if ( check_admin_referer( 'jetpack_protect_multisite_banner_opt_out' ) ) {
@@ 4264-4278 (lines=15) @@
4261
					}
4262
				}
4263
				break;
4264
			case 'jetpack-protect-multisite-opt-out':
4265
4266
				if ( check_admin_referer( 'jetpack_protect_multisite_banner_opt_out' ) ) {
4267
					// Don't show the banner again
4268
4269
					update_site_option( 'jetpack_dismissed_protect_multisite_banner', true );
4270
					// redirect back to the page that had the notice
4271
					if ( wp_get_referer() ) {
4272
						wp_safe_redirect( wp_get_referer() );
4273
					} else {
4274
						// Take me to Jetpack
4275
						wp_safe_redirect( admin_url( 'admin.php?page=jetpack' ) );
4276
					}
4277
				}
4278
				break;
4279
			case 'jetpack-manage-opt-in':
4280
				if ( check_admin_referer( 'jetpack_manage_banner_opt_in' ) ) {
4281
					// This makes sure that we are redirect to jetpack home so that we can see the Success Message.