Prevent errors from being logged twice when verbose is passed.

This commit is contained in:
Vedanshu Jain 2023-04-06 15:14:06 +05:30
parent 85c7bb6426
commit 6eca1ed561
1 changed files with 4 additions and 1 deletions

View File

@ -294,7 +294,7 @@ class CLIRunner {
* default: -1
* ---
*
* [--verbose=<verbose>]
* [--verbose]
* : Whether to output errors as they happen in batch, or output them all together at the end.
* ---
* default: false
@ -425,6 +425,9 @@ class CLIRunner {
)
);
} else {
if ( $verbose ) {
return;
}
$errors = print_r( $failed_ids, true );
return WP_CLI::error(