Skip to content

Ensure that if an empty category is passed in then try looking it up from the database

Seamus Lee requested to merge fix_reset_category into main

@john.twyman this tries to fix the problem that was identified by you and Lawrence. The only time I managed to replicate something similar to this resetting was using a traditional mailing -> create the mailing press save draft -> come back and then skip straight through and click submit. I found it was regularly resetting back to 1 after the mailing.submit call.

I couldn't trigger the same sort of thing with Mosaico. Looking at the your database that seems to back things up "

SELECT lcmc.*,cm.template_type,cm.scheduled_date FROM `log_civicrm_mailing_category` lcmc INNER JOIN civicrm_mailing cm ON cm.id = lcmc.mailing_id ORDER BY lcmc.mailing_id DESC, lcmc.log_date DESC;

Merge request reports

Loading