Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cleaned config file and display from name correctly #67

Merged
merged 3 commits into from
Nov 19, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 1 addition & 13 deletions config/mail.global.php.dist
Original file line number Diff line number Diff line change
Expand Up @@ -25,11 +25,7 @@ return [
* defaults to sendmail
**/

'transport' => Symfony\Component\Mailer\Transport\Smtp\SmtpTransport::class,

// Uncomment the below line if you want to save a copy of all sent emails to a certain IMAP folder
// Valid only if the Transport is SMTP
//'save_sent_message_folder' => ['INBOX.Sent'],
'transport' => Symfony\Component\Mailer\Transport\SendmailTransport::class,

//message configuration
'message_options' => [
Expand Down Expand Up @@ -103,14 +99,6 @@ return [
'ssl' => 'tls',
]
],

//listeners to register with the mail service, for mail events
'event_listeners' => [
//[
//'type' => 'service or class name',
//'priority' => 1
//],
],
],
// option to log the SENT emails
'log' => [
Expand Down
7 changes: 0 additions & 7 deletions docs/book/v5/configuration.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,13 +27,6 @@ Sending email with the `Smtp` transport requires valid data for the values under

> The configured path must be a writable directory

```php
'file_options' => [
'path' => 'data/mail/output',
//'callback' => null,
],
```

## Logging configuration

Uncommenting the `dot-mail.log` key will save a copy of all sent emails' subject, recipient addresses, cc and bcc addresses alongside a timestamp.
Expand Down
2 changes: 1 addition & 1 deletion docs/book/v5/transports.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

> Feel free to use any custom transport you desire, provided it implements the mentioned `TransportInterface`.

`Sendmail` is a wrapper over PHP's `mail()` function, and as such has a different behaviour on Windows than on *nix systems. Using sendmail on Windows **will not work in combination with** `addBcc()`.
PHP's `mail()` function is a wrapper over `Sendmail`, and as such has a different behaviour on Windows than on *nix systems. Using sendmail on Windows **will not work in combination with** `addBcc()`.

- Note: emails sent using the sendmail transport will be more often delivered to SPAM.

Expand Down
2 changes: 1 addition & 1 deletion src/Factory/MailServiceAbstractFactory.php
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ protected function createMessage(): Email

$from = $options->getFrom();
if (! empty($from)) {
$message->addFrom($from);
$message->addFrom($from, $options->getFromName());
}

$replyTo = $options->getReplyTo();
Expand Down
13 changes: 0 additions & 13 deletions test/CommonTrait.php
Original file line number Diff line number Diff line change
Expand Up @@ -60,11 +60,6 @@ private function generateConfig(): array
**/
'transport' => SmtpTransport::class,

// Uncomment the below line if you want to save a copy of all sent emails to a certain IMAP folder
// Valid only if the Transport is SMTP
// 'save_sent_message_folder' => ['INBOX.Sent'],

// Uncomment the below line if you want to save a copy of all sent emails to a certain IMAP folder
// Valid only if the Transport is SMTP
'save_sent_message_folder' => ['INBOX.Sent'],
'message_options' => [
Expand Down Expand Up @@ -106,14 +101,6 @@ private function generateConfig(): array
'ssl' => 'tls',
],
],

//listeners to register with the mail service, for mail events
'event_listeners' => [
//[
//'type' => 'service or class name',
//'priority' => 1
//],
],
],
// option to log the SENT emails
'log' => [
Expand Down