Skip to content
This repository has been archived by the owner on Jan 30, 2020. It is now read-only.

Commit

Permalink
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions src/Transport/Sendmail.php
Original file line number Diff line number Diff line change
Expand Up @@ -244,15 +244,15 @@ protected function prepareParameters(Mail\Message $message)

$sender = $message->getSender();
if ($sender instanceof AddressInterface) {
$parameters .= ' -r ' . $sender->getEmail();
$parameters .= ' -f ' . $sender->getEmail();
return $parameters;
}

$from = $message->getFrom();
if (count($from)) {
$from->rewind();
$sender = $from->current();
$parameters .= ' -r ' . $sender->getEmail();
$parameters .= ' -f ' . $sender->getEmail();
return $parameters;
}

Expand Down
2 changes: 1 addition & 1 deletion test/Transport/SendmailTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ public function testReceivesMailArtifactsOnUnixSystems()
$this->assertContains("From: [email protected],\r\n Matthew <[email protected]>\r\n", $this->additional_headers);
$this->assertContains("X-Foo-Bar: Matthew\r\n", $this->additional_headers);
$this->assertContains("Sender: Ralph Schindler <[email protected]>\r\n", $this->additional_headers);
$this->assertEquals('-R hdrs -r [email protected]', $this->additional_parameters);
$this->assertEquals('-R hdrs -f [email protected]', $this->additional_parameters);
}

public function testReceivesMailArtifactsOnWindowsSystems()
Expand Down

0 comments on commit 835b631

Please sign in to comment.