mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2024-11-15 03:18:26 +00:00
CakeEmail constructor now accepts $config
This commit is contained in:
parent
803cd287c2
commit
138aae670a
1 changed files with 5 additions and 1 deletions
|
@ -270,13 +270,17 @@ class CakeEmail {
|
|||
|
||||
/**
|
||||
* Constructor
|
||||
* @param mixed $config Array of configs, or string to load configs from email.php
|
||||
*
|
||||
*/
|
||||
public function __construct() {
|
||||
public function __construct($config = null) {
|
||||
$charset = Configure::read('App.encoding');
|
||||
if ($charset !== null) {
|
||||
$this->charset = $charset;
|
||||
}
|
||||
if ($config) {
|
||||
$this->config($config);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Reference in a new issue