Closed oxcid closed 1 year ago
Hi @oxcid thanks for reporting & the detailed report. Looks like you are correct! This function call: https://github.com/veritrans/SNAP-Woocommerce/blob/3736a7ca76d7b836bc2708cbcb5345c123289fe9/abstract/abstract.midtrans-gateway.php#L357-L358
Seems to be missing $order_id
(when I mis-wrote that code a while back, but seems wasn't caught during development due to it was unintentionally got into catch
block). Valid issue.
transaction_status: refund
from Midtrans, this plugin will fail to create a refund
on WC side, hence the payment status on WC versus Midtrans dashboard will not be in-sync.refund
webhook notif received.Thanks for reaching out! we'll update soon 🙏
Released fixed version v2.32.2! ✅
Please do try to install the updated version. Let us know for any issue. Thanks! 👌
Thanks @rizdaprasetya , I've installed the latest version. Will let you know if any issue still persist.
Hi,
Currently using Midtrans - WooCommerce Payment Gateway version 2.32.1.
I received an automated "midtrans Error Notification" email about not being able to reach my endpoint when sending refund notification. I noticed the error detail is InternalServerError, and I found this on my server's error log:
I confirmed that the payload from Midtrans indeed has "order_id" included. Then I checked on midtrans-woocommerce/abstract/abstract.midtrans-gateway.php, line 357:
On the second line of the above snippet, when "check_and_restore_original_order_id" function is called, there's no parameter included, while that function expects 1 parameter to be included ("midtrans-woocommerce/class/class.midtrans-utils.php").
public static function check_and_restore_original_order_id($non_duplicate_order_id)
Is this a possible cause for the error?
Thanks.