Viewing 4 replies - 1 through 4 (of 4 total)
  • Thread Starter pingram

    (@pingram3541)

    Also seeing the following in the logs on each cart page load:

    PHP Strict Standards: Declaration of USPS_Simple_Shipping_Method::calculate_shipping() should be compatible with WC_Shipping_Method::calculate_shipping($package = Array) in /mysite/public_html/mysite.net/wp-content/plugins/woo-usps-simple-shipping/class-shipping-usps.php on line 0

    When I attempt to write an override via my themes functions.php it never even hooks. I’ve tried several priorities executing a function that only writes to the log or prints the $rates array and it never shows up.

    add_filter( 'woocommerce_package_rates', 'my_hide_shipping_when_free_is_available', 1 ); //tried priorities 1, 10 and 999
    function my_hide_shipping_when_free_is_available($rates){ ... }

    I’m also receive errors after upgrading Woocommerce. Any ETA on a fix that provides compatibility for the latest Woocommerce update?

    I *think* this may be fixed by replacing the following line:

    public function calculate_shipping( $package ) {

    with

    public function calculate_shipping( $package = array() ) {

    In the plugin file class-shipping-usps.php.

    The php errors go away and the shipping costs seem to look OK in the cart.

    Please update to new version.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Shipping Zones compatible?’ is closed to new replies.