@@ 251-253 (lines=3) @@ | ||
248 | */ |
|
249 | public function reset( $args, $assoc_args ) { |
|
250 | $action = isset( $args[0] ) ? $args[0] : 'prompt'; |
|
251 | if ( ! in_array( $action, array( 'options', 'modules' ) ) ) { |
|
252 | /* translators: %s is a command like "prompt" */ |
|
253 | WP_CLI::error( sprintf( __( '%s is not a valid command.', 'jetpack' ), $action ) ); |
|
254 | } |
|
255 | ||
256 | // Are you sure? |
|
@@ 574-576 (lines=3) @@ | ||
571 | // Is the option flagged as unsafe? |
|
572 | $flagged = ! in_array( $args[1], $safe_to_modify ); |
|
573 | ||
574 | if ( ! in_array( $action, array( 'list', 'get', 'delete', 'update' ) ) ) { |
|
575 | /* translators: %s is a command like "prompt" */ |
|
576 | WP_CLI::error( sprintf( __( '%s is not a valid command.', 'jetpack' ), $action ) ); |
|
577 | } |
|
578 | ||
579 | if ( isset( $args[0] ) ) { |