From: mkanat%bugzilla.org <> Date: Fri, 4 Dec 2009 14:47:37 +0000 (+0000) Subject: Bug 531500: Allow the mailer-before_send hook to modify the arguments passed to Email... X-Git-Tag: bugzilla-3.4.5~21 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=a403010a9d9ef40641845641a33b6f974ae299ec;p=thirdparty%2Fbugzilla.git Bug 531500: Allow the mailer-before_send hook to modify the arguments passed to Email::Send Patch by Max Kanat-Alexander r=dkl, a=mkanat --- diff --git a/Bugzilla/Hook.pm b/Bugzilla/Hook.pm index de35f93b53..4833f44bfb 100644 --- a/Bugzilla/Hook.pm +++ b/Bugzilla/Hook.pm @@ -476,6 +476,9 @@ Params: =item C - The C object that's about to be sent. +=item C - An arrayref that's passed as C to +L. + =back =head2 page-before_template diff --git a/Bugzilla/Mailer.pm b/Bugzilla/Mailer.pm index 610523b8a7..2bbf62d1da 100644 --- a/Bugzilla/Mailer.pm +++ b/Bugzilla/Mailer.pm @@ -174,7 +174,8 @@ sub MessageToMTA { Debug => Bugzilla->params->{'smtp_debug'}; } - Bugzilla::Hook::process('mailer-before_send', { email => $email }); + Bugzilla::Hook::process('mailer-before_send', + { email => $email, mailer_args => \@args }); if ($method eq "Test") { my $filename = bz_locations()->{'datadir'} . '/mailer.testfile';