Skip to content

Commit

Permalink
use setFrom() #1942
Browse files Browse the repository at this point in the history
  • Loading branch information
nadar committed Aug 27, 2019
1 parent 6e280b9 commit 55b3962
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
4 changes: 4 additions & 0 deletions core/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@

All notable changes to this project will be documented in this file. This project make usage of the [Yii Versioning Strategy](https://github.com/yiisoft/yii2/blob/master/docs/internals/versions.md). In order to read more about upgrading and BC breaks have a look at the [UPGRADE Document](UPGRADE.md).

## 1.0.21

+ [#1942](https://github.com/luyadev/luya/issues/1942) Use phpmailers `setFrom()` method instead of `$from` and `$fromName` property.

## 1.0.20 (5. August 2019)

+ [#1940](https://github.com/luyadev/luya/issues/1940) Add Url helper methods `cleanHost()` and `domain()`.
Expand Down
3 changes: 1 addition & 2 deletions core/components/Mail.php
Original file line number Diff line number Diff line change
Expand Up @@ -131,8 +131,7 @@ public function getMailer()
if ($this->_mailer === null) {
$this->_mailer = new PHPMailer();
$this->_mailer->CharSet = 'UTF-8';
$this->_mailer->From = $this->from;
$this->_mailer->FromName = $this->fromName;
$this->_mailer->setFrom($this->from, $this->fromName);
$this->_mailer->isHTML(true);
$this->_mailer->XMailer = ' ';
// if sending over smtp, define the settings for the smpt server
Expand Down

0 comments on commit 55b3962

Please sign in to comment.