Skip to content

Commit

Permalink
Strict check XMailer with empty string (PHPMailer#1764)
Browse files Browse the repository at this point in the history
  • Loading branch information
szemek authored and Synchro committed Jul 2, 2019
1 parent 511413a commit 6c74e4b
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/PHPMailer.php
Original file line number Diff line number Diff line change
Expand Up @@ -527,9 +527,9 @@ class PHPMailer

/**
* What to put in the X-Mailer header.
* Options: An empty string for PHPMailer default, whitespace for none, or a string to use.
* Options: An empty string for PHPMailer default, whitespace/null for none, or a string to use.
*
* @var string
* @var string|null
*/
public $XMailer = '';

Expand Down Expand Up @@ -2380,7 +2380,7 @@ public function createHeader()
if (null !== $this->Priority) {
$result .= $this->headerLine('X-Priority', $this->Priority);
}
if ('' == $this->XMailer) {
if ('' === $this->XMailer) {
$result .= $this->headerLine(
'X-Mailer',
'PHPMailer ' . self::VERSION . ' (https://github.com/PHPMailer/PHPMailer)'
Expand Down

0 comments on commit 6c74e4b

Please sign in to comment.