• // Version 3.3.1
    PHP Fatal error: Uncaught DivisionByZeroError: Division by zero in /wp-content/plugins/woo-postfinance-checkout/includes/service/class-wc-postfinancecheckout-service-line-item.php:350

    // Version 3.2.0 - 3.3.0
    PHP Fatal error: Uncaught DivisionByZeroError: Division by zero in /wp-content/plugins/woo-postfinance-checkout/includes/service/class-wc-postfinancecheckout-service-line-item.php:345

    If I add a coupon on the checkout page that makes the total payment 0 it will show the error above.

    I had to rolback to version 3.0.11 to get rid of the error, but in the debug.log it will show errors for a table that doesn’t exist (wc_postfinancecheckout_method_config).

Viewing 3 replies - 1 through 3 (of 3 total)
  • mranner

    (@mranner)

    We have the same error: if cart total is 0, we will have an exception (crash) on the checkout page. We have fixed this issue in
    ./includes/service/class-wc-postfinancecheckout-service-line-item.php on line 350:
    $proportional_discount_amount = empty($total_amount) ? 0 : $total_discount_amount * ( $data['total'] / $total_amount );

    • This reply was modified 3 days ago by mranner.
    Thread Starter dessicubbex

    (@dessicubbex)

    Thanks for the reply, but if we change it ourselves, the changes will be overwritten if the plugin is updated and the developer doesn’t fix the error.

    Sure, we know. We commented it for the developers, because they shutdown the issue tab on github and you cannot longer report issues on the github repo.

Viewing 3 replies - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.