Ubercart and other modules work with the Mail system module. The Mandrill module can be used with Mail system but Mandrill wipes out the current settings in the mail_system variable and we have to reenter all the settings in Mail system. Mandrill could copy the approach used in Ubercart uc_store.install and other files to add and remove the Mandrill setting without wiping the other settings.

mandrill_disable(): Mandrill should check the default setting and not touch it if Mandrill is not the default. When Mandrill is the default, the code should be something like:
$mail_system = variable_get('mail_system', array('default-system' => 'DefaultMailSystem'));
if ($mail_system['default-system'] == 'MandrillMailSystem'
or $mail_system['default-system'] == 'TestingMandrillMailSystem') {
$mail_system['default-system'] == 'DefaultMailSystem';
variable_set('mail_system', $mail_system);
}

The same type of change is needed in admin submit code.

CommentFileSizeAuthor
#1 mandrill-1820380.patch2.49 KBpeterx

Comments

peterx’s picture

StatusFileSize
new2.49 KB

I tried a quick code change on our test system and include the patch. Only minimal testing.

ptmkenny’s picture

Another patch was submitted in this issue:
http://drupal.org/node/1865418

ptmkenny’s picture

Status: Active » Needs review
gcb’s picture

Status: Needs review » Fixed

fixed in dev branch, will roll into next release. Thanks @peterx!

Status: Fixed » Closed (fixed)

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

  • Commit 83684e7 on 7.x-1.x, 7.x-2.x authored by peterx, committed by gcb:
    Applied mandrill-1820380.patch by peterx, similar patch produced by...