-
Notifications
You must be signed in to change notification settings - Fork 25
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix amount mismatch #40
base: master
Are you sure you want to change the base?
Conversation
@ionandreidaniel can you provide steps to replicate the faced scenario precisely? |
Let's assume $order->get_total() = 599.80 absint($order->get_total() * 100) returns 59979 woocommerce-simplify-payment-gateway-plugin/includes/class-subscription-addon.php Line 592 in 0edcd73
In this case, the if statement condition inside the return_handler function above is never met. If we reach here woocommerce-simplify-payment-gateway-plugin/includes/class-subscription-addon.php Line 598 in 0edcd73
then inside process_standard_payments function
do_payment will be called with the amount of 599.80.
Here
(int) $amount will be equal to 599, while $this->get_total( $order ) will return (int) round( $order->get_total() * 100 ) which is equal to 59980, so amount mismatch error will be thrown. |
@ionandreidaniel We have tried to replicate as per provided details. However, not able to. Can you provide more helpful details to replicate it? Your WordPress and WooCommerce version? |
@ionandreidaniel can you provide the requested details? |
All orders are coming with the pending status |
@davids123 Thank you for raising your faced issue. We need more details to review further so we can able to assist you further. Can you raise a support ticket with following information? To raised a support ticket. Kindly create an account on https://www.ontapgroup.com/uk/customer/account/login/ and raise support ticket. (1) What is the Module version installed? (2) What is your WordPress and WooCommerce Version? (3) Provide the exact step to reproduce the issue? Along with helpful files, screenshots and videos. |
@davids123 we have not heard back on this. Can you provide details so we can take it further for you? |
No description provided.