This commit adds the `woocommerce_valid_order_statuses_for_order_again` filter to the conditional check
before displaying the order-again button.
The purpose is to enable consistency when altering the valid order again statuses - in the past a dev would
need to use this filter to let the order through the form handler, and then override the template file for a really
trivial reason just to get the button to display.
* Don't add shipping zone debug message when doing ajax
Prevent an issue where the "Customer matched zone" debug message is shown twice after first selecting a shipping method and then changing a product's quantity in cart and clicking Update cart.
* Don't pass event object to cart.update_cart
Prevent accidentally preserving cart notices when `wc_update_cart` event is triggered on body. If the event object is passed to update_cart() as the first param, it evaluates to true, forcing existing notices to be preserved.
* Pass custom arguments to cart.update_cart()
Instead of simply not passing the event object, pass any custom arguments, so it's possible to do something like: $( body ).trigger( 'wc_update_cart', true ); to still preserve notices if needed.
Replace:
`wp_remote_get() failed. Contact your hosting provider.`
`wp_remote_post() failed. Contact your hosting provider.`
With:
`%s failed. Contact your hosting provider.`
Note:
This also a good practice because the function name is outside of the translation string, this way the translator can't misspell the function name.
This PR moves the `<strong>` HTML tags from the translation strings.
Replacing: `Order scheduled for: <strong>%1$s</strong>.`
With: `Order scheduled for: %s.`
We did the same in WordPress core across several releases (4.3 - 4.7). Because it's makes the translation process to RTL language (like Hebrew) much easier.
Replace:
`The provided handler <code>%s</code> does not implement WC_Log_Handler_Interface.`
With:
`The provided handler %1$s does not implement %2$s.`
Replace:
`The class <code>%s</code> provided by woocommerce_logging_class filter must implement <code>WC_Logger_Interface</code>.`
With:
`The class %1$s provided by %2$s filter must implement %3$s.`