Commerce: `Order::EVENT_AFTER_ORDER_PAID` not firing for off site gateways

Created on 7 Dec 2018  路  4Comments  路  Source: craftcms/commerce

Description

Order::EVENT_AFTER_ORDER_PAID is not being fired for offsite gateways, specifically using the commerce-sagepay gateway.

Can confirm it is fired in 2.0.0-beta.13.1 but not 2.0.0-beta.14

Steps to reproduce

  1. Complete a transaction via the SagePay gateway.

Additional info

  • Craft version: Craft Pro 3.0.34
  • PHP version: 7.1.19
  • Database driver & version: PostgreSQL 9.5.14
  • Plugins & versions: Craft Commerce 2.0.0-beta.14

All 4 comments

I believe this is also the case when using a discount that reduces the order total to 0.

This is happening for me when a Gift Voucher code brings the total of the order to $0. It's affecting any plugin that is listening to EVENT_AFTER_ORDER_PAID to do stuff when the order is paid, such as Digital Products (create licenses), Gift Voucher (update gift code amount), etc.

It seems to be a regression that was introduced in this commit: https://github.com/craftcms/commerce/commit/80f0f1c93f5db6173fd99a864bb9f4077b2d88b7

this is also happening when complete a transaction with a multisafepay extension or with a dummy payment.

I see why this is happening. I'll do some testing to see if by fixing this I don't break anything else.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

lukeholder picture lukeholder  路  3Comments

Tam picture Tam  路  7Comments

alexanderloewe picture alexanderloewe  路  4Comments

nfourtythree picture nfourtythree  路  6Comments

palomamtnez picture palomamtnez  路  5Comments