diff --git a/src/Symfony/Component/Mailer/Tests/Transport/DsnTest.php b/src/Symfony/Component/Mailer/Tests/Transport/DsnTest.php index 04f12030da..04ee14c6cb 100644 --- a/src/Symfony/Component/Mailer/Tests/Transport/DsnTest.php +++ b/src/Symfony/Component/Mailer/Tests/Transport/DsnTest.php @@ -77,12 +77,12 @@ class DsnTest extends TestCase yield [ '//sendmail', - 'The "//sendmail" mailer DSN must contain a transport scheme.', + 'The "//sendmail" mailer DSN must contain a scheme.', ]; yield [ 'file:///some/path', - 'The "file:///some/path" mailer DSN must contain a mailer name.', + 'The "file:///some/path" mailer DSN must contain a host (use "default" by default).', ]; } } diff --git a/src/Symfony/Component/Mailer/Transport/Dsn.php b/src/Symfony/Component/Mailer/Transport/Dsn.php index 58606bd900..b5c2587d6a 100644 --- a/src/Symfony/Component/Mailer/Transport/Dsn.php +++ b/src/Symfony/Component/Mailer/Transport/Dsn.php @@ -42,11 +42,11 @@ final class Dsn } if (!isset($parsedDsn['scheme'])) { - throw new InvalidArgumentException(sprintf('The "%s" mailer DSN must contain a transport scheme.', $dsn)); + throw new InvalidArgumentException(sprintf('The "%s" mailer DSN must contain a scheme.', $dsn)); } if (!isset($parsedDsn['host'])) { - throw new InvalidArgumentException(sprintf('The "%s" mailer DSN must contain a mailer name.', $dsn)); + throw new InvalidArgumentException(sprintf('The "%s" mailer DSN must contain a host (use "default" by default).', $dsn)); } $user = isset($parsedDsn['user']) ? urldecode($parsedDsn['user']) : null;