|
@@ 185-187 (lines=3) @@
|
| 182 |
|
*/ |
| 183 |
|
public function reset( $args, $assoc_args ) { |
| 184 |
|
$action = isset( $args[0] ) ? $args[0] : 'prompt'; |
| 185 |
|
if ( ! in_array( $action, array( 'options', 'modules' ) ) ) { |
| 186 |
|
WP_CLI::error( sprintf( __( '%s is not a valid command.', 'jetpack' ), $action ) ); |
| 187 |
|
} |
| 188 |
|
|
| 189 |
|
// Are you sure? |
| 190 |
|
jetpack_cli_are_you_sure(); |
|
@@ 476-478 (lines=3) @@
|
| 473 |
|
// Is the option flagged as unsafe? |
| 474 |
|
$flagged = ! in_array( $args[1], $safe_to_modify ); |
| 475 |
|
|
| 476 |
|
if ( ! in_array( $action, array( 'list', 'get', 'delete', 'update' ) ) ) { |
| 477 |
|
WP_CLI::error( sprintf( __( '%s is not a valid command.', 'jetpack' ), $action ) ); |
| 478 |
|
} |
| 479 |
|
|
| 480 |
|
if ( isset( $args[0] ) ) { |
| 481 |
|
if ( 'get' == $args[0] && isset( $args[1] ) ) { |