diff options
| author | Greg Roach <fisharebest@webtrees.net> | 2019-09-16 23:42:46 +0100 |
|---|---|---|
| committer | Greg Roach <fisharebest@webtrees.net> | 2019-09-16 23:48:05 +0100 |
| commit | 8b45f7275a3c3b628bfa5579a1b9f315ea033ca1 (patch) | |
| tree | 0eb53353c0f49051f3ba94719776177a0512c3d4 | |
| parent | 4d99955e5797e1e12688b8d0592d207a63b2c6c6 (diff) | |
| download | webtrees-8b45f7275a3c3b628bfa5579a1b9f315ea033ca1.tar.gz webtrees-8b45f7275a3c3b628bfa5579a1b9f315ea033ca1.tar.bz2 webtrees-8b45f7275a3c3b628bfa5579a1b9f315ea033ca1.zip | |
Fix: wrong default for SMTP sender field
| -rw-r--r-- | app/Schema/SeedGedcomSettingTable.php | 2 | ||||
| -rw-r--r-- | app/Schema/SeedSiteSettingTable.php | 2 | ||||
| -rw-r--r-- | app/TreeUser.php | 4 |
3 files changed, 5 insertions, 3 deletions
diff --git a/app/Schema/SeedGedcomSettingTable.php b/app/Schema/SeedGedcomSettingTable.php index fa9521542b..197997af0d 100644 --- a/app/Schema/SeedGedcomSettingTable.php +++ b/app/Schema/SeedGedcomSettingTable.php @@ -100,7 +100,7 @@ class SeedGedcomSettingTable implements SeedInterface 'THUMBNAIL_WIDTH' => '100', 'USE_RIN' => '0', 'USE_SILHOUETTE' => '1', - 'WEBTREES_EMAIL' => 'webtrees-noreply@localhost', + 'WEBTREES_EMAIL' => '', 'WORD_WRAPPED_NOTES' => '0', ]; diff --git a/app/Schema/SeedSiteSettingTable.php b/app/Schema/SeedSiteSettingTable.php index b253129708..b72dd7aaac 100644 --- a/app/Schema/SeedSiteSettingTable.php +++ b/app/Schema/SeedSiteSettingTable.php @@ -34,7 +34,7 @@ class SeedSiteSettingTable implements SeedInterface 'SMTP_AUTH' => '1', 'SMTP_SSL' => 'none', 'SMTP_HELO' => 'localhost', - 'SMTP_FROM_NAME' => 'localhost', + 'SMTP_FROM_NAME' => 'no-reply@localhost', ]; /** diff --git a/app/TreeUser.php b/app/TreeUser.php index 62e5f902c9..9b60c5ffa7 100644 --- a/app/TreeUser.php +++ b/app/TreeUser.php @@ -56,7 +56,9 @@ class TreeUser implements UserInterface */ public function email(): string { - return $this->tree->getPreference('WEBTREES_EMAIL', 'no-reply@example.com'); + $default = Site::getPreference('SMTP_FROM_NAME', 'no-reply@localhost'); + + return $this->tree->getPreference('WEBTREES_EMAIL', $default); } /** |
