The MDVA-32739 Magento patch fixes the issue where enabling asynchronous email notifications sends out old sales emails. This patch is available when the Magento Quality Patch (MQP) tool 1.0.12 is installed. Please note that the issue is scheduled to be fixed in Magento 2.4.2.
Affected products and versions
The patch is created for Magento version:
Magento Commerce Cloud 2.3.5-p2.
Compatible with Magento versions:
Magento Commerce and Magento Commerce Cloud 2.3.0 - 2.4.1.
Note: the patch can be applicable to other versions. To check if the patch is compatible with your Magento version, run ./vendor/bin/magento-patches status
.
Issue
Steps to reproduce:
1. Disable asynchronous email sending.
2. Create an order and make sure sending of the email is failing.
3. Enable asynchronous sending.
Actual result:
The old email will be sent out via the cronjob.
Expected result:
Emails are sent out only for those orders, shipments, invoices and credit memos, which were created after the last asynchronous sending update.
Fix
With the fix included in the patch, Magento will select orders that are created after the asynchronous sending method has been last ran and will send the email for such orders.
By default, it will select with an offset of -1 day. You can change this value (to -2 days for example) by modifying di.xml
.
Apply the patch
For instructions on how to apply an MQP patch, use the following links depending on your Magento product:
- Magento Commerce: DevDocs Apply patches using Magento Quality Patches Tool.
- Magento Commerce Cloud: DevDocs Upgrades and Patches > Apply patches.
Related reading
To learn more about Magento Quality Patches, refer to:
- Magento Quality Patches released: a new tool to self-serve quality patches.
- Check patch for Magento issue with Magento Quality Patches.
For info about other patches available in MQP tool, refer to the Patches available in MQP tool section.