-
Notifications
You must be signed in to change notification settings - Fork 3.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Stripping - from default Message-ID header.
This fixes issues where certiain spamassassin rules would flag EmailComponent messages as spam due to too many - in the messageID. Fixes #2019
- Loading branch information
Showing
2 changed files
with
2 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -589,7 +589,7 @@ function _createHeader() { | |
|
||
if ($this->messageId !== false) { | ||
if ($this->messageId === true) { | ||
$headers['Message-ID'] = '<' . String::uuid() . '@' . env('HTTP_HOST') . '>'; | ||
$headers['Message-ID'] = '<' . str_replace('-', '', String::uuid()) . '@' . env('HTTP_HOST') . '>'; | ||
This comment has been minimized.
Sorry, something went wrong.
This comment has been minimized.
Sorry, something went wrong.
markstory
Author
Member
|
||
} else { | ||
$headers['Message-ID'] = $this->messageId; | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
When sending mails through shell/CLI
env('HTTP_HOST')
will be empty, so we should probably fix that too.