Kirill Posted February 26, 2018 Share Posted February 26, 2018 Hello. Just noticed a rare flow that still created some troubles for us. Our flow: on invoice create we copy products list to a separate module table; after certain date on daily cronjob our module checks if the invoices were paid and if not, suspends user services (unless they are in protected group); on invoice payment services are unsuspended; on invoice cancellation the record is deleted. For one of our customers invoice was merged to other invoice. So the original one was just silently deleted without invoking cancellation hook. And our suspension script was a bit "confused" by invoice id that doesn't have user or some other data at all. I understand that I should just add some additional check to make sure invoice still exists. But would be nice if invoice merge action either triggers invoice cancel hook or has its own one. Link to comment Share on other sites More sharing options...
Recommended Posts