Compatibility issue with Sequential Order Nº when payment callbacks
-
Hello! 🙂
I believe there may be a compatibility issue between the Komoju WooCommerce plugin and Sequential Order Numbers for WooCommerce plugins: https://wordpress.org/plugins/woocommerce-sequential-order-numbers/
Environment
- WordPress: Latest version
- WooCommerce: Latest version
- Komoju for WooCommerce
- Sequential Order Number plugin enabled
Problem Description
Our store uses a Sequential Order Number plugin, which generates a custom order number stored in the
_order_numbermeta field.When a customer is redirected to Komoju, the payment reference sent to Komoju appears to be the sequential order number (for example,
105432) rather than the internal WooCommerce order ID.However, when Komoju receives the payment confirmation and processes the callback/webhook, it appears to attempt to load the WooCommerce order directly using that reference as if it were the internal order ID.
This causes one of two issues:
- The order cannot be found.
- A different/older WooCommerce order is updated because its internal ID matches the sequential order number used as the payment reference.
Example
- WooCommerce internal order ID:
254781 - Sequential order number (
_order_number):105432
Komoju receives reference
105432.When the payment is completed, the plugin appears to look for WooCommerce order ID
105432instead of searching for the order whose_order_numberequals105432.As a result, the payment status may be applied to the wrong order.
Expected Behavior
If the payment reference sent to Komoju is the sequential order number, the callback should locate the order by that reference (for example using
_order_number) and then retrieve the actual WooCommerce order ID before updating the order status.Additional Information
This issue only becomes visible when the sequential order number differs from the WooCommerce internal order ID, which is the normal behavior when using sequential order number plugins.
Could you please verify whether the callback/webhook logic is using the payment reference directly as the WooCommerce order ID?
Thank you 😀
You must be logged in to reply to this topic.