From: Michael M Slusarz Date: Mon, 1 Feb 2010 23:21:32 +0000 (-0700) Subject: Remove globals reference in Horde_Mime_Mdn X-Git-Url: https://git.internetallee.de/?a=commitdiff_plain;h=3c90188e4f6d8218962305182862652933210d69;p=horde.git Remove globals reference in Horde_Mime_Mdn --- diff --git a/framework/Mime/lib/Horde/Mime/Mdn.php b/framework/Mime/lib/Horde/Mime/Mdn.php index 79642fa1a..46049e716 100644 --- a/framework/Mime/lib/Horde/Mime/Mdn.php +++ b/framework/Mime/lib/Horde/Mime/Mdn.php @@ -125,6 +125,7 @@ class Horde_Mime_Mdn * 'displayed' * 'deleted' * + * @param string $name The name of the local server. * @param string $maildriver The mail driver used to send the message. * @param array $mailparams Any parameters the mail driver may need. * @param array $mod The list of modifications. @@ -139,7 +140,7 @@ class Horde_Mime_Mdn * * @throws Horde_Mime_Exception */ - public function generate($action, $sending, $type, $maildriver, + public function generate($action, $sending, $type, $name, $maildriver, $mailparams = array(), $mod = array(), $err = array()) { @@ -200,7 +201,7 @@ class Horde_Mime_Mdn /* The second part is a machine-parseable description. */ $part_two = new Horde_Mime_Part('message/disposition-notification'); - $part_two_text = array('Reporting-UA: ' . $GLOBALS['conf']['server']['name'] . '; ' . $ua . "\n"); + $part_two_text = array('Reporting-UA: ' . $name . '; ' . $ua . "\n"); if (!empty($orig_recip)) { $part_two_text[] = 'Original-Recipient: rfc822;' . $orig_recip . "\n"; } diff --git a/imp/lib/Ui/Message.php b/imp/lib/Ui/Message.php index 3006815f1..9c71596ab 100644 --- a/imp/lib/Ui/Message.php +++ b/imp/lib/Ui/Message.php @@ -114,7 +114,7 @@ class IMP_Ui_Message /* Send out the MDN now. */ try { $mail_driver = IMP_Compose::getMailDriver(); - $mdn->generate(false, $confirmed, 'displayed', $mail_driver['driver'], $mail_driver['params']); + $mdn->generate(false, $confirmed, 'displayed', $GLOBALS['conf']['server']['name'], $mail_driver['driver'], $mail_driver['params']); IMP_Maillog::log('mdn', $msg_id, 'displayed'); $success = true;