Code Duplication    Length = 5-8 lines in 2 locations

class.jetpack-cli.php 2 locations

@@ 328-335 (lines=8) @@
325
				}
326
				WP_CLI::success( __( 'Modules reset to default.', 'jetpack' ) );
327
				break;
328
			case 'modules':
329
				if ( ! $is_dry_run ) {
330
					$default_modules = Jetpack::get_default_modules();
331
					Jetpack::update_active_modules( $default_modules );
332
				}
333
334
				WP_CLI::success( __( 'Modules reset to default.', 'jetpack' ) );
335
				break;
336
			case 'prompt':
337
				WP_CLI::error( __( 'Please specify if you would like to reset your options, modules or sync-checksum', 'jetpack' ) );
338
				break;
@@ 536-540 (lines=5) @@
533
					WP_CLI::error( sprintf( __( '%s could not be activated.', 'jetpack' ), $module['name'] ) );
534
				}
535
				break;
536
			case 'activate_all':
537
				$modules = Jetpack::get_available_modules();
538
				Jetpack::update_active_modules( $modules );
539
				WP_CLI::success( __( 'All modules activated!', 'jetpack' ) );
540
				break;
541
			case 'deactivate':
542
				$module = Jetpack::get_module( $module_slug );
543
				Jetpack::log( 'deactivate', $module_slug );