The uc_order_status_email_update trigger is being pulled before uc_order_comment_save in function uc_order_view_update_form_submit. As a result, the email that goes to the customer does not contain the latest comment.

Additionally, the trigger is not pulled at all unless the order status is also changed. Therefore if the admin adds a comment and checks the 'send email' checkbox but does not change the order status, no email will be sent (and they probably will not realize that is the case as they would expect an email to be sent.) If this part is by design then we should at least display a message to inform the admin that no email was sent in this condition.

Patch pulls the trigger call to the end of the function and lets it fire regardless of whether the status was changed.

CommentFileSizeAuthor
update-email.patch1.58 KBJody Lynn
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

rszrama’s picture

Status: Needs review » Fixed

Excellent find. I verified the bug on the 2.x Livetest, applied the patch, and it works!

Thanks again, Jody. Committing right now.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.