4.0.14 Release Notes
Version 4.0.14 is a patch release with four bug fixes and a security improvement.
Download 4.0.14
Bug Fixes
PHP Warning When Checking Per-Product Payment Method Settings
On PHP 8, the plugin could write PHP Warning: Undefined array key "enabled" to the log when it evaluated a payment method's per-product settings for a product that could not be loaded, such as a trashed product, a deleted variation, or an item left in an abandoned cart. The settings lookup now falls back to the correct default value in that situation.
This was recorded as a warning on PHP 8.0 and later, and as a notice that PHP suppressed by default on earlier versions. It had no effect on checkout or on which payment methods were offered.
PHP Warning on Refunds Created from the Stripe Dashboard
When a refund created from the Stripe Dashboard refunded an order in full, WooCommerce logged Warning: Undefined array key "refund_total" while restocking the order's items.
The plugin builds the refund's line items when it receives the refund event from Stripe, and current WooCommerce versions expect each line item to include its total and tax. The plugin now includes those values, so the refund is recorded without the warning. The refund amount itself was always applied correctly.
500 Error on Requests That Run Before WooCommerce Has Loaded
Some requests that don't involve WooCommerce, such as a feed URL like /feed/, can run before WooCommerce has finished loading, depending on the other plugins and caching layers on a site. In that situation the plugin could call a WooCommerce function that wasn't available yet and end the request with a fatal error and a 500 response.
The plugin's page-context code now confirms that WooCommerce is loaded before it runs, and does nothing when it isn't, so these requests complete normally.
Checkout Stalled With a Saved Apple Pay, Google Pay, That Required Authentication
When a customer selected a saved Apple Pay, Google Pay, or Link Checkout payment method from the regular payment method list at checkout, and the payment required additional authentication (such as a 3D Secure challenge from the bank), the authentication step never appeared and checkout stopped without an error message.
The plugin now shows the authentication challenge for these saved payment methods, so the customer can complete it and the order can go through. This only affected payment methods chosen from the regular list; paying with the express checkout buttons was not affected.
Security
Improved Validation of Payment Method Tokens
The validation of saved payment method tokens was improved for added security.