error log full of WC3.0 “doing it wrong” warnings
-
The plugin is using WooCommerce 2.x style properties which spams the error log with tons of warnings like so:
PHP message: billing_last_name was called incorrectly. Order properties should not be accessed directly. Backtrace: require('wp-blog-header.php'), require_once('wp-includes/template-loader.php'), do_action('template_redirect'), WP_Hook->do_action, WP_Hook->apply_filters, WC_AJAX::do_wc_ajax, do_action('wc_ajax_checkout'), WP_Hook->do_action, WP_Hook->apply_filters,WC_AJAX::checkout, WC_Checkout->process_checkout, WC_Checkout->process_order_payment, WC_Gateway_Coinpayments->process_payment, WC_Gateway_Coinpayments->generate_coinpayments_url, WC_Gateway_Coinpayments->get_coinpayments_args, WC_Abstract_Legacy_Order->__get, wc_doing_it_wrong. This message was added in version 3.0.
There is a repeat of each warning for each property accessed during a checkout: status, billing_country, billing_phone, id, order_key, billing_first_name, billing_last_name, billing_email
Directly accessing order properties is deprecated since Woo 3.0 and plugin authors are supposed to update their plugins to access order details via the get_*() methods instead.
Please shake the bitcoin cookie jar until you find some budget to fix your plugin. Its vociferous spamming of the error_log makes it hard to spot actual problems with your store.
- The topic ‘error log full of WC3.0 “doing it wrong” warnings’ is closed to new replies.