Closed rrennick closed 3 years ago
When running this, I found that emails were still sent out. This was the flow I followed:
wp wc generate orders
commandwp-admin/tools.php?page=wpml_plugin_log
and note the number incrementsrefresh the WP Mail log page at wp-admin/tools.php?page=wpml_plugin_log and note the number increments
@zhongruige In my environment, I don't have any emails logged in trunk
or this branch. Which emails did you see logged?
@rrennick I was seeing the following emails come in:
The only difference I can think of is I was testing this using a hosted environment where the the emailer is set up and emails are sent, while, for example, I know in some local environments emails aren't actually sent out. So maybe that could be the difference?
@zhongruige Thanks for the review. I've updated the PR to unhook all the transactional emails.
This PR unhooks the WooCommerce customer and order emails when generating objects via the WP CLI command. The performance improvement in my dev environment on 1000 orders was ~15%.
Closes #13
Testing
1- Run
wp wc generate orders
1- Runwp wc generate customers