In ProgressShopping cart is empty

Viewing 6 posts - 31 through 36 (of 36 total)
  • Author
    Posts
  • #36285
    Alex
    Keymaster

    Hello,

    I am looking at it.

    Will let you know.

    Regards,
    Alex

    #36287
    rene
    Participant

    Do you need any login details?

    #36288
    Alex
    Keymaster

    No, you already provided them.

    Regards,
    Alex

    #36293
    Alex
    Keymaster

    Hello Rene,

    We have examined our code carefully and we are not calling get_cart before ‘wp_loaded’ action.
    Also we couldn’t reproduce the problem even with the premium version of the Delivery Drivers for Vendors plugin.

    Another approach you can do is to deactivate one by one all other plugins and check if the problem disappears and look at this plugin.

    A final workaround would be to comment out the line 83 from “class-lafka-shipping-areas.php”, but this will lead to not proper calculation of the delivery rates per distance (if you use them)

    Regards,
    Alex

    #36297
    rene
    Participant

    Hello Alex,
    If I comment out line 83 in “class-lafka-shipping-areas.php” then I can call up the shopping cart and the products are also visible in the shopping cart, even if I only comment out lines 425 – 432
    /*public static function clear_wc_shipping_rates_cache() {
    if ( isset( WC()->cart ) ) {
    $packages = WC()->cart->get_shipping_packages();
    foreach ( $packages as $package_key => $package ) {
    WC()->session->set( ‘shipping_for_package_’ . $package_key, false ); // Or true
    }
    }
    }*/
    it works and the products are also in the shopping cart visible. However, when I put it back to its original state, there are no products in the shopping cart. I do not understand that entirely.

    Regards,
    Rene

    #36300
    Alex
    Keymaster

    Hi Rene,

    Commenting out line 83 is enough to bypass this function. Means that the rates cache will not be cleared and will not lead to removing the products from the cart content (This doesn’t mean that the cart is cleared by Lafka)

    My point is that by commenting this line and leaving it like this the cart works as expected, but calculation of the route will not work correctly.

    Again, if you want to find the real problem, you need to deactivate all the plugins one by one and see which one is causing this ..

    Regards,
    Alex

Viewing 6 posts - 31 through 36 (of 36 total)

You must be logged in and have valid license to reply to this topic.

License required for the following item
Login and Registration Log in · Register