summaryrefslogtreecommitdiff
path: root/Postman/PostmanWpMail.php
diff options
context:
space:
mode:
authorYehuda Hassine <yehuda@myinbox.in>2019-05-12 23:19:58 +0300
committerYehuda Hassine <yehuda@myinbox.in>2019-05-12 23:19:58 +0300
commit038dc3839338d5384d263f2488a6f67adf99ec7c (patch)
tree9f4f9d4e109aac6f30b19418e410474b2cc71f28 /Postman/PostmanWpMail.php
parent75e5f6e319d5d36f3076fe2eb449bb089b8ce3da (diff)
downloadPost-SMTP-038dc3839338d5384d263f2488a6f67adf99ec7c.zip
Dummy PHPMailer delivery + Message Id handler
Diffstat (limited to 'Postman/PostmanWpMail.php')
-rw-r--r--Postman/PostmanWpMail.php9
1 files changed, 1 insertions, 8 deletions
diff --git a/Postman/PostmanWpMail.php b/Postman/PostmanWpMail.php
index 3d1f8f5..66b3279 100644
--- a/Postman/PostmanWpMail.php
+++ b/Postman/PostmanWpMail.php
@@ -42,10 +42,6 @@ if ( ! class_exists( 'PostmanWpMail' ) ) {
// initialize for sending
$this->init();
- if ( ! is_array( $headers ) ) {
- $headers = explode( "\n", str_replace( "\r\n", "\n", $headers ) );
- }
-
// build the message
$postmanMessage = $this->processWpMailCall( $to, $subject, $message, $headers, $attachments );
@@ -65,11 +61,8 @@ if ( ! class_exists( 'PostmanWpMail' ) ) {
* @return PostmanMessage
*/
private function apply_default_headers( $message ) {
- $headers = $message->getHeaders();
$headers[] = 'Message-ID: ' . $this->createMessageId();
$message->addHeaders($headers);
-
- return $message;
}
/**
@@ -182,7 +175,7 @@ if ( ! class_exists( 'PostmanWpMail' ) ) {
*/
public function sendMessage( PostmanMessage $message, PostmanEmailLog $log ) {
- $message = $this->apply_default_headers( $message );
+ $this->apply_default_headers( $message );
// get the Options and AuthToken
$options = PostmanOptions::getInstance();