Co-Authors-Plus icon indicating copy to clipboard operation
Co-Authors-Plus copied to clipboard

BUG: create_guest_author() private method does not display anything when WP_Error is returned

Open oscarssanchez opened this issue 2 years ago • 0 comments

It seems the intended behavior of: https://github.com/Automattic/Co-Authors-Plus/blob/master/php/class-wp-cli.php#L886 is failing as of now. If I try these steps I'm not able to see what was the problem with the CSV, or if there was a problem at all:

1.- Use this sample file test.csv 2.- Run command: wp co-authors-plus create-guest-authors-from-csv --file=test.csv 3.- See the following output:

Screen Shot 2022-10-27 at 19 20 13

Since create() only returns WP_Error or the guest author id, I think we can instead check if the returned value is a WP_Error

oscarssanchez avatar Oct 28 '22 00:10 oscarssanchez