From 995dd48856823e403bf38bdca2fda5c9e4bfd766 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Tim=20D=C3=BCsterhus?= Date: Thu, 2 Jun 2016 22:35:15 +0200 Subject: [PATCH] Improve parameter order in RecipientAwareTextMimePart --- .../files/lib/system/email/mime/HtmlTextMimePart.class.php | 2 +- .../files/lib/system/email/mime/PlainTextMimePart.class.php | 2 +- .../system/email/mime/RecipientAwareTextMimePart.class.php | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/wcfsetup/install/files/lib/system/email/mime/HtmlTextMimePart.class.php b/wcfsetup/install/files/lib/system/email/mime/HtmlTextMimePart.class.php index bfaabad003..803f967c98 100644 --- a/wcfsetup/install/files/lib/system/email/mime/HtmlTextMimePart.class.php +++ b/wcfsetup/install/files/lib/system/email/mime/HtmlTextMimePart.class.php @@ -17,6 +17,6 @@ class HtmlTextMimePart extends RecipientAwareTextMimePart { * @param string $content Content of this text part. */ public function __construct($content) { - parent::__construct($content, 'text/html', 'email_html'); + parent::__construct('text/html', 'email_html', 'wcf', $content); } } diff --git a/wcfsetup/install/files/lib/system/email/mime/PlainTextMimePart.class.php b/wcfsetup/install/files/lib/system/email/mime/PlainTextMimePart.class.php index 3e3ba8494c..e72c50b07c 100644 --- a/wcfsetup/install/files/lib/system/email/mime/PlainTextMimePart.class.php +++ b/wcfsetup/install/files/lib/system/email/mime/PlainTextMimePart.class.php @@ -17,6 +17,6 @@ class PlainTextMimePart extends RecipientAwareTextMimePart { * @param string $content Content of this text part. */ public function __construct($content) { - parent::__construct($content, 'text/plain', 'email_plaintext'); + parent::__construct('text/plain', 'email_plaintext', 'wcf', $content); } } diff --git a/wcfsetup/install/files/lib/system/email/mime/RecipientAwareTextMimePart.class.php b/wcfsetup/install/files/lib/system/email/mime/RecipientAwareTextMimePart.class.php index 14c4d7fbc9..405a28b0fa 100644 --- a/wcfsetup/install/files/lib/system/email/mime/RecipientAwareTextMimePart.class.php +++ b/wcfsetup/install/files/lib/system/email/mime/RecipientAwareTextMimePart.class.php @@ -39,12 +39,12 @@ class RecipientAwareTextMimePart extends TextMimePart implements IRecipientAware /** * Creates a new AbstractRecipientAwareTextMimePart. * - * @param string $content Content of this text part (this is passed to the template). * @param string $mimeType Mime type to provide in the email. You *must* not provide a charset. UTF-8 will be used automatically. * @param string $template Template to evaluate * @param string $application Application of the template to evaluate (default: wcf) + * @param string $content Content of this text part (this is passed to the template). */ - public function __construct($content, $mimeType, $template, $application = 'wcf') { + public function __construct($mimeType, $template, $application = 'wcf', $content = '') { parent::__construct($content, $mimeType); $this->template = $template; -- 2.20.1